/* =========================================
   HERO SECTION 
   ========================================= */
.hero {
    height: calc(100vh);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    overflow: hidden;
    position: relative;
    background-color: #000;
}

/* Nuevo formato para el Banner Hero */
.hero-bg-real {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    z-index: 0;
}

.hero-img-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: linear-gradient(90deg, rgba(0, 10, 27, 0.308) 100%);
    z-index: 1;
}

/* Es vital asegurarte de que tu clase hero-content tenga esto: */
.hero-content {
    /* Estas dos líneas son las nuevas para que el texto se vea por encima de la foto */
    position: relative;
    z-index: 2;
    
    /* Estas son tus reglas originales para centrar TODO al milímetro */
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 4rem 2%;
}

.hero-content-bold {
    font-family: 'Baloo 2', sans-serif;
    font-weight: 1000;
}

.hero-content-blue {
    font-weight: 1000;
    color: #ffffff;
}

.hero h1 {
    font-size: 45px;
    max-width: 100%;
    margin-bottom: 1.5rem;
    font-weight: 400;
    line-height: 1.1;
    color: white;
    text-transform: uppercase;
    font-family: 'Baloo 2', cursive;
}

.hero p {
    font-size: 1.1rem;
    max-width: 90%;
    margin-bottom: 2.5rem;
    font-family: "Montserrat", sans-serif;
    font-weight: 600;
    color: white;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.hero-btn-main {
    text-decoration: none;
    background: var(--primary);
    color: white;
    padding: 0.8rem 2.5rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.9rem;
    transition: 0.3s;
    box-shadow: 0 4px 6px rgba(0, 86, 179, 0.2);
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: "Montserrat", sans-serif;
}

.hero-btn-main:hover {
    background: #2fbaea;
    transform: translateY(-1px);
}

.btn-outline-dark {
    color: white;
    font-size: 0.9rem;
    background: transparent;
    padding: 0.8rem 1.5rem;
    border-radius: 50px;
    font-weight: 700;
    transition: 0.3s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #ffffff;
}

.btn-outline-dark:hover {
    transform: translateY(-1px);
    background-color: var(--hero-text);
}

/* Añade esto al principio de tu CSS si no lo tienes ya, 
   hace que el salto entre secciones sea un deslizamiento suave */
html {
    scroll-behavior: smooth;
}

/* =========================================
   SCROLL INDICATOR (VERSIÓN VISTOSA)
   ========================================= */
.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: #ffffff;
    text-decoration: none;
    opacity: 0.95;
    /* Opacidad casi al máximo */
    z-index: 10;
    transition: opacity 0.3s ease, transform 0.3s ease;
    /* Sombra clave para separarlo del fondo claro de la furgoneta */
    filter: drop-shadow(0px 2px 4px rgba(0, 0, 0, 0.6));
}

.scroll-indicator:hover {
    opacity: 1;
    transform: translateX(-50%) translateY(-3px);
    /* Pequeño salto al pasar el ratón */
}

.scroll-text {
    font-family: "Montserrat", sans-serif;
    font-size: 15px;
    /* Un punto más grande */
    font-weight: 700;
    /* Más negrita */
    letter-spacing: 0.2em;
    text-transform: uppercase;
}

.scroll-chevron {
    width: 28px;
    /* Icono más grande */
    height: 28px;
    animation: subtle-bounce 2.5s infinite ease-in-out;
}

/* Nueva línea vertical que guía la vista hacia abajo */
.scroll-line {
    width: 2px;
    height: 30px;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 1), rgba(255, 255, 255, 0));
    border-radius: 2px;
    margin-top: -5px;
    animation: line-stretch 2.5s infinite ease-in-out;
}

/* Animación del rebote del chevron */
@keyframes subtle-bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(6px);
    }
}

/* Animación de la línea estirándose */
@keyframes line-stretch {

    0%,
    100% {
        height: 30px;
        opacity: 0.5;
    }

    50% {
        height: 45px;
        opacity: 1;
    }
}

/* =========================================
   TRUST BAR (LOGOS)
   ========================================= */
.trust-bar {
    padding: 2rem 5%;
    text-align: center;
    overflow: hidden;
    border-bottom: 1px solid #d3d3d3;
    background-color: var(--fondo-suave);
}

.trust-bar h1 {
    color: var(--hero-text);
    font-size: 20px;
    font-family: 'Baloo 2', sans-serif;
    text-transform: uppercase;
}

.logo-carousel-section {
    background-color: var(--color-blanco);
    padding: var(--padding-seccion-vertical) 0;
}

.logo-carousel {
    width: 100%;
    overflow: hidden;
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%);
}

.logo-track {
    display: flex;
    width: calc(200px * 20);
    animation: scroll 40s linear infinite;
    animation-play-state: running;
    /* AÑADE ESTO: Activa la GPU y evita tirones */
    will-change: transform;
    transform: translateZ(0); 
    -webkit-transform: translateZ(0);
}

.logo-track:hover {
    animation-play-state: paused;
}

.logo-slide {
    width: 200px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 1rem;
    flex-shrink: 0;
    min-height: 100px;
}

.logo-slide img {
    max-width: 50%;
    max-height: 80px;
    transition: 0.2s ease-in-out;
    filter: grayscale(50%);
}

.logo-slide:hover img {
    opacity: 1;
    transform: scale(1.1);
    filter: grayscale(0%);
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* =========================================
   ULTIMOS PROYECTOS (LP)
   ========================================= */

.logo-carousel-lp {
    width: 100%;
    margin-bottom: 60px;
    overflow: hidden;
    /* -webkit-mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%); */
}

.logo-track-lp {
    display: flex;
    width: max-content;
    gap: 30px;
    animation: scroll 60s linear infinite;
    animation-play-state: running;

    /* AÑADE ESTO: Activa la GPU y evita tirones */
    will-change: transform;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
}

.logo-track-lp:hover {
    animation-play-state: paused;
}

.logo-slide-lp {
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
    height: 250px;
}

.logo-slide-lp img {
    height: 100%;
    width: auto;
    object-fit: contain;
    transition: 0.2s ease-in-out;
    border-radius: 20px;
}

.logo-slide-lp:hover img {
    opacity: 1;
    transform: scale(1.1);
    filter: grayscale(0%);
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }

    /* ATENCIÓN: El cálculo debe ser -50% menos la mitad del gap que hayas puesto arriba (en este caso 15px porque el gap es 30px) para que el bucle no dé tirones */
    100% {
        transform: translateX(calc(-50% - 15px));
    }
}


/* =========================================
   SERVICIOS DESTACADOS
   ========================================= */
.services-main {
    padding: 5rem 5%;
    background-color: var(--fondo-suave);
}

.servicios-main {
    text-align: center;
    margin-bottom: 4px;
}

.servicios-main h2 {
    font-size: 30px;
    color: var(--hero-text);
    margin-bottom: 4rem;
    font-weight: 900;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2.5rem;
    margin-top: 50px;
}

.service-card-impresion,
.service-card-rotulacion,
.service-card-personalizacion {
    background: white;
    border: 1px solid #eee;
    border-radius: 12px;
    overflow: hidden;
    transition: 0.3s;
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.08);
}

.service-card-impresion {
    transform: translateY(0);
}

.service-card-rotulacion {
    transform: translateY(0);
}

.service-card-personalizacion {
    transform: translateY(0);
}

.service-card-impresion:hover {
    transform: translateY(-20px);
    box-shadow: 0 20px 30px rgba(0, 0, 0, 0.08);
    border-color: transparent;
}

.service-card-rotulacion:hover {
    transform: translateY(-20px);
    box-shadow: 0 20px 30px rgba(0, 0, 0, 0.08);
    border-color: transparent;
}

.service-card-personalizacion:hover {
    transform: translateY(-20px);
    box-shadow: 0 20px 30px rgba(0, 0, 0, 0.08);
    border-color: transparent;
}

/* Nuevo formato para las tarjetas de servicios */
.card-img {
    height: 220px;
    background-color: #f0f0f0;
    display: flex;
    overflow: hidden; 
}

.card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover; 
    transition: transform 0.5s ease; /* Pequeño extra opcional para que sea fluido */
}

.card-content {
    padding: 2rem;
}

.card-content h2 {
    color: var(--primary);
    margin-bottom: 0.8rem;
    font-size: 1.4rem;
    font-weight: 700;
}

.card-content p {
    color: #555;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

.link-more {
    color: var(--hero-text);
    font-weight: 700;
    border-bottom: 2px solid var(--primary);
    font-size: 0.9rem;
    padding-bottom: 2px;
}

/* =========================================
   ÚLTIMOS PROYECTOS (VERSIÓN PORTADA)
   ========================================= */
#ultimos-proyectos {
    padding-top: 50px;
    background-color: var(--fondo-suave);
    text-align: center;
    font-family: 'Baloo 2', sans-serif;
}

.project-container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-header h2 {
    font-family: 'Baloo 2', sans-serif;
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--hero-text);
    margin-bottom: 10px;
    line-height: 1.2;
    text-transform: uppercase;
}

.section-header .highlight {
    color: var(--primary);
}

.section-header p {
    font-family: 'Baloo 2', sans-serif;
    color: #666;
    font-size: 1.1rem;
    margin-bottom: 50px;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 50px;
}

.project-card {
    display: block;
    text-decoration: none;
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    will-change: transform, box-shadow;
    backface-visibility: hidden; /* Evita parpadeos al hacer el hover */
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.image-wrapper {
    overflow: hidden;
    height: 250px;
}

.project-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.project-card:hover img {
    transform: scale(1.1);
}

.project-info {
    padding: 20px;
    text-align: left;
}

.project-info h3 {
    margin: 0;
    font-size: 1.2rem;
    color: var(--hero-text);
    font-weight: 700;
}

.project-info span {
    font-size: 0.9rem;
    color: var(--primary);
    font-weight: 600;
    margin-top: 5px;
    display: inline-block;
}

/* =========================================
   INTRO STATEMENT
   ========================================= */
.intro-statement {
    background-color: var(--fondo-suave);
    padding: 4rem 5rem 4rem;
    text-align: center;
    border-bottom: 1px solid rgba(123, 123, 123, 0.345);
    font-family: 'Montserrat', sans-serif;
}

.intro-statement h2 {
    font-size: 35px;
    font-weight: 900;
    color: var(--hero-text);
    margin-bottom: 1.5rem;
    letter-spacing: -1px;
    line-height: 1;
}

.intro-statement p {
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--hero-text);
    padding: 0 20px;
}

.separator-line {
    width: 200px;
    height: 3px;
    background-color: var(--hero-text);
    margin: 2rem auto;
    border-radius: 2px;
}

/* =========================================
   SECCIÓN: POR QUÉ ELEGIRNOS (MODERNA)
   ========================================= */
.trust-section {
    padding: 120px 20px;
    background-color: var(--hero-text);
    position: relative;
    z-index: 5;

    /* VITAL: Si ves un hueco blanco gigante arriba por culpa 
       del translateY de tus tarjetas anteriores, descomenta esta línea 
       y ajusta el número hasta que quede bien pegado: */
    /* margin-top: -80px; */
}

.trust-container {
    display: flex;
    max-width: 1200px;
    margin: 0 auto;
    gap: 60px;
    align-items: flex-start;
}

/* Columna Izquierda: Texto Fijo */
.trust-text {
    flex: 1;
    position: sticky;
    top: 100px;
    /* Se queda pegado al hacer scroll */
}

.trust-text h2 {
    font-size: 3rem;
    color: white;
    line-height: 1.1;
    margin: 0 0 20px 0;
}

.trust-text p {
    font-size: 1.1rem;
    color: white;
    line-height: 1.6;
    margin-bottom: 30px;
}

.trust-text .btn-yellow {
    display: inline-block;
    background: var(--primary);
    /* Asegúrate de que este botón destaque */
    color: white;
    padding: 15px 35px;
    border-radius: 50px;
    font-weight: 700;
    text-decoration: none;
    text-transform: uppercase;
    box-shadow: 0 4px 10px rgba(0, 54, 88, 0.2);
    transition: 0.3s;
}

.trust-text .btn-yellow:hover {
    background-color: #2fbaea;
    transform: translateY(-2px);
}

/* Columna Derecha: Grid de Tarjetas */
.trust-grid {
    flex: 1.2;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.trust-card {
    background: #f8fbff;
    border-radius: 24px;
    padding: 40px 30px;
    border: 1px solid #e6f0f9;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    position: relative;
    overflow: hidden;
}

/* Tarjetas impares un poco más abajo para dar estilo "escalera" */
.trust-card:nth-child(odd) {
    transform: translateY(30px);
}

.trust-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 54, 88, 0.08);
    border-color: #2fbaea;
}

/* Ajuste del hover para las tarjetas impares (para que no den un salto raro) */
.trust-card:nth-child(odd):hover {
    transform: translateY(20px);
}

.trust-icon {
    font-size: 2.5rem;
    color: #2fbaea;
    margin-bottom: 25px;
}

.trust-card h3 {
    font-family: 'Baloo 2', sans-serif;
    font-size: 1.5rem;
    color: var(--primary);
    margin: 0 0 15px 0;
    line-height: 1.2;
}

.trust-card p {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.6;
    margin: 0;
}

/* =========================================
   RESPONSIVE SECCIÓN CONFIANZA
   ========================================= */
@media (max-width: 992px) {
    .trust-container {
        flex-direction: column;
        gap: 40px;
    }

    .trust-text {
        position: static;
        /* Quitamos el sticky en tablets */
        text-align: center;
    }

    .trust-card:nth-child(odd),
    .trust-card:nth-child(odd):hover {
        transform: translateY(0);
        /* Quitamos el efecto escalera */
    }

    .trust-card:hover {
        transform: translateY(-5px);
    }
}

@media (max-width: 600px) {
    .trust-section {
        padding: 80px 20px;
    }

    .trust-grid {
        grid-template-columns: 1fr;
        /* 1 sola columna en móviles */
    }

    .trust-text h2 {
        font-size: 2.2rem;
    }
}

/* =========================================
   PROCESO 4 PASOS
   ========================================= */
.proceso-section {
    padding: 6rem 0;
    background-color: var(--fondo-suave);
    border-top: 1px solid #eee;
}

.header-proceso {
    text-align: center;
    margin-bottom: 5rem;
}

.header-proceso h2 {
    font-size: 2.5rem;
    color: var(--hero-text);
    font-weight: 900;
    font-family: 'Montserrat', sans-serif;
}

.proceso-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 3rem;
    text-align: center;
    position: relative;
}

@media(min-width: 900px) {
    .proceso-grid::before {
        content: '';
        position: absolute;
        top: 25px;
        left: 10%;
        right: 10%;
        height: 2px;
        background: #eee;
        z-index: 0;
    }
}

.paso-card {
    position: relative;
    z-index: 1;
    background: transparent;
}

.paso-numero {
    background-color: var(--primary);
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-weight: 700;
    font-size: 1.1rem;
    margin: 0 auto 1.5rem auto;
    box-shadow: 0 8px 15px rgba(0, 86, 179, 0.25);
    transition: 0.3s;
}

.paso-card:hover .paso-numero {
    transform: scale(1.1);
    background-color: var(--hero-text);
    box-shadow: 0 8px 15px rgba(136, 136, 136, 0.4);
}

.paso-card h3 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: #333;
    font-weight: 700;
}

.paso-card p {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.6;
}

@media (max-width: 1024px) {
    .hero {
        position: relative;
        /* Fundamental: esto encierra a la imagen absoluta */
        background-color: var(--fondo-suave);
        height: calc(100dvh - 85px);
        /* La altura se la damos al contenedor, no a la imagen */
        display: flex;
        align-items: center;
        justify-content: center;
        overflow: hidden;
    }

    /* Anulamos tu display: contents. Necesitamos que esta caja agrupe los textos */
    .hero-content {
        position: relative;
        z-index: 2;
        /* Esto es lo que pone el texto por encima de la imagen */
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 100%;
    }

    .hero-img {
        position: absolute;
        /* Saca la imagen del flujo normal y la manda al fondo */
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 1;
        /* Se queda por debajo del texto (que tiene 2) */
        background-image: linear-gradient(90deg, rgba(0, 10, 27, 0.308) 100%), url('../img/index/fondoinicio13.jpg');
        background-size: cover;
        background-position: center;
        margin: 0;
        /* Fuera márgenes */
    }

    /* TÍTULO (Eliminamos el order) */
    .hero h1 {
        font-size: 1.8rem;
        text-align: center;
        margin-bottom: 1.5rem;
        text-transform: none;
        line-height: 1.2;
    }

    /* PÁRRAFO (Eliminamos el order) */
    .hero p {
        text-align: left;
        margin-bottom: 2rem;
        font-size: 1rem;
        font-weight: 600;
    }

    /* BOTONES (Eliminamos el order) */
    .hero-buttons {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 1.5rem;
        box-sizing: border-box;
        padding: 0rem 5%;
    }

    .hero-btn-main {
        width: 100%;
        text-align: center;
        padding: 1rem;
    }

    .btn-outline-dark {
        width: 100%;
        /* Corregido tu "width: 100;" que era inválido sin unidad */
        padding: 0.9rem 2rem;
        color: white;
        background: transparent;
        border: 2px solid white;
        text-decoration: none;
        text-transform: none;
        display: flex;
        justify-content: center;
    }

    .servicios-main h2 {
        font-size: 20px;
        color: var(--hero-text);
        margin-bottom: 4rem;
        font-weight: 900;
    }

    /* Resto de tu código responsive original que no pertenece al Hero */
    .services-grid,
    .proceso-grid {
        grid-template-columns: 1fr;
    }

    .services-main {
        padding-top: 50px;
        background-color: var(--fondo-suave);
    }

    .section-header h2 {
        font-size: 1.5rem;
    }

    .intro-statement {
        background-color: var(--fondo-suave);
        padding: 4rem 0rem 4rem;
        text-align: center;
        border-bottom: 1px solid rgba(123, 123, 123, 0.345);
    }

    .intro-statement h2 {
        font-size: 1.5rem;
    }

    .intro-statement p {
        font-size: 0.8rem;
    }

    .pre-cta {
        background: var(--hero-text);
        padding: 60px 0px 60px 0px;
        text-align: center;
    }

    .pre-cta h2 {
        color: white;
        margin-bottom: 25px;
        font-size: 1.2rem;
    }

    .header-proceso h2 {
        font-size: 1.4rem;
        color: var(--hero-text);
        font-weight: 900;
    }

    .trust-text h2 {
        font-size: 1.5rem;
        color: white;
        line-height: 1.1;
        margin: 0 0 20px 0;
    }

    .trust-text p {
        font-size: 1rem;
        color: white;
        line-height: 1.6;
        margin-bottom: 30px;
    }
}