:root {
    --color-azul-marino: #030b1b;
    --color-blaco: #fff;
    --color-negro: #000;
    --color-beige-suave: #f5eae4;
    --color-rojo-intenso: #fe0032;
}


* {
    padding: 0;
    margin: 0;
    text-decoration: none;
    list-style: none;
    box-sizing: border-box;
    font-family: sans-serif;
}

body{
    overflow-x: hidden;
    background: var(--color-negro);
}

.logo img{
  width: 50px;
}

header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: var(--color-negro);
  z-index: 1000;
}

.header-container {
  max-width: 1440px;
  margin: 0 auto;
  width: 100%;
  height: 100px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 40px;
}

nav ul{
    display: flex;
    gap: 40px;
}

nav a{
    color: var(--color-blaco);
    font-size: 22px;
    font-weight: 700;
    transition: color 0.4s;
    position: relative;
}

nav a:hover{
  color: var(--color-rojo-intenso);
}

.menu-toggle {
  display: none;
  font-size: 35px;
  color: var(--color-blaco);
  cursor: pointer;
  transition: transform 0.5s ease;
}

.menu-toggle.rotate {
  transform: rotate(180deg);
}

.nav-menu {
  transition: transform 0.4s ease, opacity 0.4s ease;
}




.hero {
    position: relative;
    background-image: url('/imagenes/fondo-banner.jpg');
    background-repeat: no-repeat;
    background-position: center;
    background-size: cover;
    height: 100vh;
    display: flex;
    padding: 4px 0;
    overflow: hidden;
    margin-top: 0px; /* altura del header fijo */
}

.hero::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to left, rgba(0, 0, 0, 8) 10%, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.8));
    pointer-events: none; 
    z-index: 1;
}



.contenido-hero{
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: row-reverse;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1440px;
    margin: 0 auto;
    padding: 60px 40px;
}

.hero-text{
    flex: 1;
    padding: 0 40px;
    text-align: left;
    color: var(--color-blaco);
}

.hero-text h1{
    font-size: 50px;
    margin-bottom: 20px;
}

#typing-text {
  font-size: 50px;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
  border-right: 2px solid var(--color-rojo-intenso); 
  width: 0;
}

#typing-text span {
  color: var(--color-rojo-intenso);
}

@keyframes typingLoop {
  0%   { width: 0; }
  30%  { width: 22ch; }  /* escribe */
  50%  { width: 22ch; }  /* mantiene visible */
  70%  { width: 0; }     /* borra */
  100% { width: 0; }     /* pausa después de borrar */
}

@keyframes blink {
  50% { border-color: transparent; }
}


.hero-text p{
    font-size: 25px;
    text-align: center;
}

.hero-image img{
    width: 100%;
    padding-top: 250px;
    filter: brightness(0.8) contrast(1.0);
}

/* seccion cuadros */

.proyectos {
  position: relative;
  height: auto;
  padding: 50px 20px;
  color: white;
  background-color: #000;
  overflow: hidden;
}

.parallax-bg {
  background-position: center;
  position: absolute;
  width: 100%;
  height: 100%;
  z-index: -1;
  top: 0;
  left: 0;
}

    .titulo,
    .cuadro {
    opacity: 0;
    transition: all 2s ease;
    }

    /* Elimina animation: slideDown */
    .titulo {
    font-size: 2.5rem;
    margin-bottom: 60px;
    text-align: center;
    transform: translateY(-50px);
    }

    .titulo.visible {
    opacity: 1;
    transform: translateY(0);
    }

    .cuadro.izquierda {
    transform: translateX(-300px);
    }

    .cuadro.derecha {
    transform: translateX(300px);
    }

    .cuadro.visible {
    opacity: 1;
    transform: translateX(0);
    }



.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
  max-width: 1000px;
  margin: 0 auto;
}

.cuadro {
  background: rgba(255, 255, 255, 0.05);
  border: 2px solid #fe003322;
  border-radius: 10px;
  overflow: hidden;
  text-align: center;
  opacity: 0;
}

.cuadro img {
  width: 100%;
  height: auto;
  display: block;
}

.texto {
  padding: 20px;
  color: white;
}

.texto h3 {
  margin: 0;
  font-size: 1.4rem;
}

.texto small {
  color: #ccc;
  font-size: 0.9rem;
}


@keyframes slideDown {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideLeft {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideRight {
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.boton-proyectos {
  display: inline-block;
  margin-top: 15px;
  padding: 10px 20px;
  background-color: var(--color-rojo-intenso);
  color: #000;
  text-decoration: none;
  font-weight: bold;
  border-radius: 5px;
  transition: background-color 0.3s ease;
}

.boton-proyectos:hover {
  background-color: var(--color-negro);
  color: var(--color-rojo-intenso);
}







/* Tablets o pc pequeñas */
@media (min-width: 769px) and (max-width: 1280px) {
    .menu-toggle {
    display: block;
  }

  .nav-menu {
    position: absolute;
    top: 90px;
    left: 0;
    width: 100%;
    padding: 0 0 50px 0;
    background: var(--color-rojo-intenso);
    transform: translateY(-200px);
    opacity: 0;
    pointer-events: none;
    flex-direction: column;
    align-items: center;
    z-index: 100;
    transition: 1s;
  }

  .nav-menu.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav-menu ul {
    flex-direction: column;
    gap: 20px;
    padding: 20px 0;
    align-items: center;
    z-index: 100;
  }
}