/* === PALETA DE COLORES Y VARIABLES === */
:root {
    --pink: #ffc4e1;
    --brown: #3f221b;
    --cream: #f9f7ed;
    --green: #b6d545;
    --font-main: 'Poppins', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-main);
    color: var(--brown);
    background-color: var(--pink);
}

h1, h2, h3, h4 {
    font-weight: 900;
    text-transform: uppercase;
    line-height: 1.1;
    font-size: clamp(1.8rem, 5vw, 4rem);
    word-break: break-word;
}

.hero-top img {
  max-width: 60%;         /* Controls the image size (e.g., 60% of the container width) */
  height: auto;           /* Maintains aspect ratio */
  border-radius: 15px;    /* Optional: adds a slight rounded corner */
  display: block;
  margin: 0 auto;         /* Ensures the image is centered within its column */
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 30px;
}

/* === 1. HERO === */
.hero-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 40px;
    margin-top: 40px;
    flex-wrap: wrap;
    gap: 20px;
}
.hero-top h1 { font-size: 5rem; max-width: 500px; }
.hero-top-text { max-width: 400px; font-size: 1.1rem; font-weight: 600; }
.hero-top-text a {
    color: var(--brown);
    text-decoration: underline;
    font-weight: 900;
    display: inline-block;
    margin-top: 10px;
}
.hero-image {
    width: 100%;
    height: 100%;
    scale: 20%;
    object-fit: cover;
    display: block;
    margin: 0;
}
#hero-container { padding-bottom: 0; }

/* === 2. JOURNEY === */
.journey-section {
    display: flex;
    background-color: var(--cream);
    flex-wrap: wrap;
}
.journey-left {
    flex: 1;
    min-width: 300px;
    display: flex;
    flex-direction: column;
    background-color: var(--brown);
}
.video-container {
    width: 100%;
    height: 400px;
    overflow: hidden;
    line-height: 0;
    position: relative;
}
.video-container video {
    width: 100%;
    height: 120%;
    display: block;
    object-fit: cover;
    position: absolute;
    top: -10%;
    left: 0;
}
.journey-quote {
    color: white;
    padding: 50px;
    box-sizing: border-box;
    font-size: 1.2rem;
    font-weight: 700;
    text-align: center;
    margin-top: auto;
}
.journey-right {
    flex: 1;
    min-width: 300px;
    padding: 80px 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.journey-right h2 { margin-bottom: 20px; }

/* === 3. SERVICES === */
.services-section {
    background-color: var(--green);
    display: flex;
    padding: 80px 20px;
    gap: 40px;
    flex-wrap: wrap;
}
.services-left { flex: 1; min-width: 300px; display: flex; align-items: center; }
.services-right { flex: 1.5; min-width: 300px; display: flex; flex-direction: column; gap: 20px; }
.service-card {
    background-color: var(--cream);
    padding: 30px;
    display: flex;
    align-items: center;
    gap: 30px;
}
.service-icon { width: 80px; height: 80px; background-color: var(--pink); flex-shrink: 0; }
.service-text h3 { font-size: 1.5rem; margin-bottom: 5px; }

/* === 4. WINS / CARRUSEL DE PROYECTOS (estilo grid original, 3 visibles) === */
.wins-section { background-color: var(--pink); text-align: center; }
.wins-section h2 { margin-bottom: 40px; }

.carousel-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    gap: 16px;
}
.carousel-viewport {
    overflow: hidden;
    flex: 1;
}
.carousel-track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: calc((100% - 60px) / 3);
    gap: 30px;
    transition: transform 0.5s ease;
}
.win-card { background-color: var(--cream); }
.win-img { height: 200px; background-color: #ddd; overflow: hidden; }
.win-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.win-content { padding: 30px; }
.win-content h3 { font-size: 1.3rem; margin-bottom: 10px; }
.win-btn {
    display: inline-block;
    background-color: var(--brown);
    color: white;
    padding: 12px 25px;
    text-decoration: none;
    font-weight: 900;
    border-radius: 30px;
    margin-top: 20px;
    text-transform: uppercase;
}

.carousel-arrow {
    background-color: var(--brown);
    color: var(--cream);
    border: none;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    font-size: 1.3rem;
    cursor: pointer;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s;
}
.carousel-arrow:hover { opacity: 0.8; }

/* === 5. TESTIMONIALS / CARRUSEL === */
.testimonials-header {
    background-color: var(--brown);
    color: var(--cream);
    text-align: center;
    padding: 60px 20px 20px;
}
.testimonials-header h2 { margin: 0; }

.test-carousel-section {
    background-color: var(--brown);
    padding-bottom: 50px;
}
.test-carousel-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 30px;
    display: flex;
    align-items: center;
    gap: 16px;
}
.test-carousel-viewport { overflow: hidden; flex: 1; }
.test-carousel-track {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 50%;
    gap: 0;
    transition: transform 0.5s ease;
}
.test-card {
    flex: 0 0 50%;
    min-width: 300px;
    padding: 60px;
    text-align: center;
}
.test-card.cream { background-color: var(--cream); }
.test-card.green { background-color: var(--green); }
.test-img { width: 100%; height: 250px; background-color: #ccc; margin-bottom: 20px; overflow: hidden; }
.test-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.test-img img[alt]::after { display: none; }
/* Ocultar texto alt cuando imagen no carga */
.test-img img:not([src]), .test-img img[src=""] { visibility: hidden; }
.test-text { font-size: 1.2rem; font-style: italic; margin-bottom: 20px; }

/* === 6. CONNECT === */
/* === 6. CONNECT === */
.connect-section {
    background-color: var(--pink);
    display: flex;
    flex-wrap: wrap;
    gap: 60px;
    align-items: center;
}
.connect-left {
    flex: 1;
    min-width: 300px;
    display: flex;
    flex-direction: column;
    gap: 32px;
}
.connect-left h2 { margin-bottom: 0; }

.cv-buttons {
    display: flex;
    flex-direction: row;
    gap: 14px;
    flex-wrap: wrap;
}
.cv-btn {
    display: inline-block;
    background-color: var(--brown);
    color: var(--pink);
    padding: 12px 24px;
    text-decoration: none;
    font-family: var(--font-main);
    font-weight: 900;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    border-radius: 30px;
    text-align: center;
    transition: opacity 0.2s;
    white-space: nowrap;
}
.cv-btn:hover { opacity: 0.8; }
.cv-btn-en {
    background-color: transparent;
    color: var(--brown);
    border: 2.5px solid var(--brown);
}

/* Libreta */
.notebook {
    background-color: var(--cream);
    border-radius: 4px;
    position: relative;
    padding: 28px 28px 28px 48px;
    box-shadow: 3px 3px 0px var(--brown);
    border: 2px solid var(--brown);
    line-height: 2;
    font-weight: 600;
    font-size: 1rem;
}
.notebook::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 4px;
    background-image: repeating-linear-gradient(
        to bottom,
        transparent,
        transparent calc(2rem - 1px),
        rgba(63, 34, 27, 0.15) calc(2rem - 1px),
        rgba(63, 34, 27, 0.15) 2rem
    );
    background-size: 100% 2rem;
    background-position: 0 28px;
    pointer-events: none;
}
.notebook::after {
    content: '';
    position: absolute;
    top: 0;
    left: 36px;
    bottom: 0;
    width: 2px;
    background-color: rgba(180, 60, 60, 0.35);
}
.notebook p { position: relative; z-index: 1; }
.notebook a {
    color: var(--brown);
    text-decoration: none;
    font-weight: 700;
    border-bottom: 1.5px solid var(--brown);
}
.notebook a:hover { opacity: 0.7; }

.connect-right {
    flex: 1;
    min-width: 300px;
    display: flex;
    flex-direction: column;
    gap: 24px;
    padding: 0;
    background: transparent;
    justify-content: center;
}
.mailto-box { text-align: left; }
.mailto-text {
    font-size: 1rem;
    font-weight: 400;
    margin-bottom: 16px;
    color: var(--brown);
    line-height: 1.6;
}
.mailto-btn {
    display: inline-block;
    width: auto;
    padding: 14px 36px;
    text-decoration: none;
    text-align: center;
    border-radius: 30px;
}
.mailto-fallback {
    margin-top: 10px;
    font-size: 0.82rem;
    color: var(--brown);
    opacity: 0.65;
}
.copy-email-btn {
    background: none;
    border: none;
    text-decoration: underline;
    font-weight: 700;
    font-family: var(--font-main);
    font-size: 0.82rem;
    color: var(--brown);
    cursor: pointer;
    padding: 0;
    margin-left: 4px;
}

.submit-btn {
    width: 100%;
    background-color: var(--brown);
    color: white;
    padding: 15px;
    border: none;
    border-radius: 10px;
    font-size: 1.2rem;
    font-weight: 900;
    cursor: pointer;
}

/* === RESPONSIVE === */
@media (max-width: 900px) {
    .carousel-track { grid-auto-columns: calc((100% - 30px) / 2); }
}
@media (max-width: 768px) {
    .hero-top h1 { font-size: 3rem; }
    .journey-section, .services-section, .connect-section { flex-direction: column; }
    .carousel-track { grid-auto-columns: 100%; }
    .test-carousel-track { grid-auto-columns: 100%; }
}