@font-face {
    font-family: 'FuenteCarnot'; /* Ponle el nombre que quieras usar internamente */
    src: url('../fonts/HippopotamusApocalypse-Gzly.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}


/* Estilo base del logo con la animación aplicada */
.hero-logo {
    width: 250px;
    max-width: 70%;
    height: auto;
    margin-bottom: 10px;
    
    /* Aquí empieza la magia del NEÓN */
    /* Aplicamos el color rojo de tu marca al brillo */
    filter: drop-shadow(0 0 2px var(--rojo-carnot)) 
            drop-shadow(0 0 8px var(--rojo-carnot));
            
    /* La animación: nombre, duración, repetición */
    animation: neon-flicker 4s infinite;
}



/* --- Definición de la animación de parpadeo --- */
/* Estos porcentajes simulan un fallo eléctrico errático */
@keyframes neon-flicker {
    0%, 19%, 21%, 23%, 25%, 54%, 56%, 100% {
        /* Estado: ENCENDIDO (Brillo intenso) */
        filter: drop-shadow(0 0 5px var(--rojo-carnot))
                drop-shadow(0 0 15px var(--rojo-carnot))
                brightness(1.2); /* Un pequeño extra de brillo a la imagen */
        opacity: 1;
    }
    20%, 24%, 55% {
        /* Estado: APAGADO/TENUE (El parpadeo rápido) */
        filter: drop-shadow(0 0 2px rgba(216, 96, 88, 0.3)); /* Sombra muy débil */
        brightness(0.7); /* La imagen se oscurece un poco */
        opacity: 0.9;
    }
}



/* --- VARIABLES DE CARNOT FACTORY --- */
:root {
    --gris-principal: #2F2F2F;   /* Tu negro personalizado */
    --rojo-carnot: #a6514c;      /* Tu rojo personalizado */
    --blanco-sucio: #F4F4F4;
    --gris-texto: #BDC3C7;
    --negro-profundo: #1A1A1A;   /* Para sombras y contrastes */
}

/* --- RESET & BASE --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--gris-principal);
    color: var(--blanco-sucio);
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
    scroll-behavior: smooth;
}

h1, h2, h3, h4 {
    font-family: 'Oswald', sans-serif;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.container-factory {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0px 20px;
}

/* --- NAVEGACIÓN --- */
nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 5%;
    background: var(--negro-profundo);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 5px solid var(--rojo-carnot);
}

.logo { font-size: 2.5rem; font-weight: bold; font-family: 'FuenteCarnot'; letter-spacing: 3px;}
.logo span { color: #D86058; }

/* Nuevo contenedor para agrupar Logo + Icono a la izquierda */
.nav-left-group {
    display: flex;
    align-items: center;
    gap: 25px; /* Espacio entre el logo y la casita */
}

/* Estilo del enlace del icono */
.nav-home-icon {
    color: white; /* Color inicial igual que los otros enlaces */
    display: flex; /* Para centrar el SVG perfectamente */
    align-items: center;
    transition: 0.3s ease;
    opacity: 0.8; /* Un poco más sutil que el logo */
}

/* Efecto Hover */
.nav-home-icon:hover {
    color: var(--rojo-carnot); /* Se ilumina con tu rojo */
    opacity: 1;
    transform: translateY(-2px); /* Pequeño saltito */
}

/* Asegurar que el SVG use el color del texto */
.nav-home-icon svg {
    fill: currentColor;
}

/* --- Ajuste para Móvil (Opcional pero recomendado) --- */
@media (max-width: 768px) {
    .nav-left-group {
       gap: 15px; /* Menos espacio en pantallas chicas */
    }
    .nav-home-icon svg {
        width: 20px; /* Icono un poco más chico en móvil */
        height: 20px;
    }
}
.nav-links { display: flex; list-style: none; margin-left: auto;}
.nav-links li { margin-left: 25px; }
.nav-links a { 
    color: white; 
    text-decoration: none; 
    font-size: 0.9rem;
    transition: 0.3s;
}
.nav-links a:hover { color: var(--rojo-carnot); }

/* --- HERO SECTION CORREGIDO --- */
/* --- HERO SECTION CORREGIDO (Sin Parallax) --- */
#hero {
    height: 60vh;     
    min-height: 450px; 
    width: 100%;
    
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #1A1A1A;
    opacity: 0.7;
    
    position: relative;
    
    /* FONDO: Actualizado el nombre y quitado el efecto fijo */
    background-image:
    /* 1. Sombra SUPERIOR: De negro fuerte (0%) a transparente rápido (15%) */
    linear-gradient(to bottom, rgba(0,0,0,0.8) 0%, transparent 30%),

    /* 2. Sombra INFERIOR: De negro fuerte (0%) a transparente rápido (15%) */
    linear-gradient(to top, rgba(0,0,0,0.8) 0%, transparent 30%),

    /* 3. TU FOTO DE FONDO REAL (¡IMPORTANTE: Va al final!) */
    url('../assets/img/hero/Ladrillos.png');
    background-size: cover;
    background-position: center;
    /* background-attachment: fixed;  <-- ESTA LÍNEA SE ELIMINA */
    
    overflow: hidden;
    padding-top: 60px; 
    z-index: 1;
}

/* --- CONTENEDOR DIVIDIDO --- */
.hero-split {
    display: flex;
    width: 100%;
    max-width: 1200px; /* Evita que se estire demasiado en pantallas gigantes */
    
    /* Esto asegura que el TEXTO y el LOGO estén alineados a la misma altura entre sí */
    align-items: center; 
    justify-content: space-between;
}

/* Bloque de TEXTO */
.hero-text {
    flex: 1;
    text-align: left;
    padding-right: 20px;
    z-index: 2;
}


/* Bloque de IMAGEN/LOGO */
.hero-visual {
    flex: 1;
    display: flex;
    justify-content: center; /* Centra el logo en su mitad */
    align-items: center;
}

/* El logo mantiene tu efecto neón */
.hero-logo {
    width: 300px; /* Un poco más grande en desktop */
    max-width: 100%;
    filter: drop-shadow(0 0 5px #fff)
            drop-shadow(0 0 15px var(--rojo-carnot))
            drop-shadow(0 0 30px var(--rojo-carnot));
    animation: neon-flicker 4s infinite alternate;
    z-index: ;
}

/* --- CLASES PARA LA ANIMACIÓN --- */
/* Estado inicial (invisible y desplazado a la izquierda) */
.hidden-left {
    opacity: 0;
    transform: translateX(-100px); /* Empieza 100px a la izquierda */
    transition: all 1s ease-out; /* Suavidad del movimiento */
}

/* Estado final (visible y en su sitio) */
.show-left {
    opacity: 1;
    transform: translateX(0);
}


/* El Título (El Gancho) - Versión más compacta */
.hook-title {
  /* Antes era 2.8rem, lo bajamos a 2rem (aprox 32px) */
  font-size: 1.4rem; 
  text-transform: ;
  font-weight: 700;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.7);
  line-height: 1.3; /* Un poco más de aire entre líneas para que respire */
  color: #ffffff;
  margin-bottom: 12px; /* Reducimos el espacio inferior también */
}

/* El Subtítulo (La Explicación) */
.hook-subtitle {
  /* Antes era 1.25rem, lo bajamos a 1rem (aprox 16px, tamaño estándar de lectura) */
  font-size: 1.2rem; 
/* Esto crea una nube oscura detrás del texto */
text-shadow: 0 0 5px rgba(0,0,0,0.9), 0 0 10px rgba(0,0,0,0.6);
  font-style: italic;
  font-family: 'Bodoni MT';
  font-weight: 400; /* Le quitamos peso (antes 300) para que se lea mejor al ser más chico */
  color: #bebebe;
  letter-spacing: normal; /* Quitamos el espaciado extra */
  max-width: 600px; /* Limitamos el ancho para que no se extienda demasiado */
  margin: 0 auto; /* Centramos el bloque de texto */
}

/* Ajuste para celulares (Responsive) */
@media (max-width: 768px) {
  .hook-title {
    font-size: 1.5rem; /* Aprox 24px en móvil, muy legible sin ocupar toda la pantalla */
  }
  .hook-subtitle {
    font-size: 0.95rem; /* Apenas más chico que el estándar */
  }
}

/* --- MOBILE RESPONSIVE --- */
@media (max-width: 768px) {
    .hero-split {
        flex-direction: column-reverse; /* INVIERTE EL ORDEN: Texto abajo, Logo arriba */
        justify-content: center;
        text-align: center;
    }

    .hero-text {
        text-align: center;
        padding-right: 0;
        margin-top: 20px;
    }

    .hero-logo {
        width: 200px; /* Más pequeño en móvil */
        margin-bottom: 20px;
    }
}

.btn-main {
    display: inline-block;
    margin-top: 25px;
    padding: 15px 40px;
    background: var(--rojo-carnot);
    color: white;
    text-decoration: none;
    font-weight: bold;
    border-radius: 2px;
    transition: 0.3s ease;
}
.btn-main:hover {
    background: white;
    color: var(--rojo-carnot);
    transform: scale(1.05);
}

/* --- PORTFOLIO: EXPANDING CARDS (CODEPEN STYLE) --- */
#portfolio {
    padding: 30px 0;
    background-color: var(--negro-profundo);
    border-top: 40px solid var(--gris-principal);
}

#portfolio h2 {
    text-align: center;
    margin-bottom: 40px;
    color: var(--rojo-carnot);
}

.expanding-cards {
    display: flex;
    width: 90vw;
    max-width: 1100px;
    margin: 0 auto;
}

.panel {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    height: 60vh;
    border-radius: 25px; /* Ajustado para suavidad visual */
    color: #fff;
    cursor: pointer;
    flex: 0.5;
    margin: 10px;
    position: relative;
    transition: flex 0.7s ease-in;
    border: 1px solid rgba(216, 96, 88, 0.2);
}

.panel h3 {
    font-size: 20px;
    position: absolute;
    bottom: 25px;
    left: 25px;
    margin: 0;
    opacity: 0;
    background: rgba(47, 47, 47, 0.6);
    padding: 5px 15px;
    border-radius: 5px;
}

.panel.active {
    flex: 5;
    border: 2px solid var(--rojo-carnot);
}

.panel.active h3 {
    opacity: 1;
    transition: opacity 0.3s ease-in 0.4s;
}

/* --- RESEÑAS (3 COLUMNAS) --- */
#resenas {
    background-color: var(--gris-principal);
    margin-bottom: 40px;
    margin-top: 20px;
}

.grid-resenas {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-top: 20px;
}

.col-resena {
    text-align: center;
    background: var(--negro-profundo);
    padding: 40px 20px;
    border-radius: 10px;
    border-top: 4px solid var(--rojo-carnot);
}

.perfil-foto {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    margin: 0 auto 20px;
    overflow: hidden;
    border: 3px solid var(--rojo-carnot);
}

.perfil-foto img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.nombre {
    color: var(--rojo-carnot);
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.texto {
    font-size: 0.95rem;
    color: var(--gris-texto);
    font-style: italic;
}

/* --- CONTACTO & FOOTER --- */
#contacto {
    text-align: center;
    background: var(--negro-profundo);
    padding: 40px
}

.btn-whatsapp {
    display: inline-block;
    padding: 15px 30px;
    background: #25D366;
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: bold;
    margin-top: 20px;
}

footer {
    padding: 40px;
    text-align: center;
    background: var(--gris-principal);
    border-top: 1px solid #3d3d3d;
    color: #777;
    font-size: 0.8rem;
}

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
    .grid-resenas {
        grid-template-columns: 1fr;
    }
    
    .expanding-cards {
        width: 95vw;
    }

    .panel:nth-of-type(4), .panel:nth-of-type(5) {
        display: none; /* Oculta tarjetas para que no se vea apretado en móvil */
    }
}

/* Contenedor principal para centrar y organizar */
.social-container {
  display: flex;
  justify-content: center; /* Cambia a 'flex-start' si los quieres a la izquierda */
  gap: 15px; /* Espacio entre botones */
  margin-top: 20px;
  flex-wrap: wrap; /* Para que se ajusten en móviles pequeños */
}

/* Estilo base del botón */
.social-btn {
  display: flex;
  align-items: center;
  gap: 10px; /* Espacio entre icono y texto */
  text-decoration: none;
  font-family: sans-serif; /* Usa tu tipografía aquí */
  font-weight: 600;
  color: white;
  padding: 12px 24px;
  border-radius: 50px; /* Bordes redondeados modernos */
  transition: all 0.3s ease; /* Suaviza las animaciones */
  box-shadow: 0 4px 6px rgba(0,0,0,0.1); /* Sombra sutil */
}

/* Colores Oficiales */
.whatsapp {
  background-color: #25D366;
}

.instagram {
  background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285AEB 90%);
}

.facebook {
  background-color: #1877F2;
}

/* Efecto al pasar el mouse (Hover) */
.social-btn:hover {
  transform: translateY(-3px); /* Se eleva un poco */
  box-shadow: 0 6px 12px rgba(0,0,0,0.2); /* La sombra crece */
  filter: brightness(1.1); /* Se ilumina ligeramente */
}

/* Ajuste responsive (opcional) */
@media (max-width: 600px) {
  .social-btn span {
    display: none; /* Oculta el texto en móviles muy pequeños, dejando solo el icono */
  }
  .social-btn {
    padding: 12px; /* Reduce el padding si solo hay icono */
    border-radius: 50%; /* Los hace circulares si no hay texto */
  }
}

/* Botón Instagram Circular */
.insta-icon-btn {
    display: inline-flex;
    justify-content: center; /* Centra el icono horizontalmente */
    align-items: center;     /* Centra el icono verticalmente */
    
    width: 36px;  /* Tamaño del círculo */
    height: 36px; 
    border-radius: 50%; /* Lo hace redondo */
    
    background-color: transparent; /* Fondo transparente por defecto */
    border: 1px solid #555; /* Un borde gris sutil */
    color: #777; /* Color del icono gris */
    
    margin-top: -10px;
    margin-bottom: 15px;
    
    transition: all 0.3s ease;
}

/* Efecto Hover (Al pasar el mouse) */
.insta-icon-btn:hover {
    color: white; /* El icono se vuelve blanco para contrastar */
    background-color: var(--rojo-carnot); /* El fondo se llena de tu rojo */
    border-color: var(--rojo-carnot);
    transform: scale(1.1) rotate(5deg); /* Crece un poco y gira sutilmente */
    box-shadow: 0 0 10px rgba(216, 96, 88, 0.4); /* Resplandor rojo */
}

/* Ajuste del SVG para que obedezca al color del texto */
.insta-icon-btn svg {
    fill: currentColor;
}


/* =========================================
   ESTILOS PARA PÁGINA "SOBRE MÍ"
   ========================================= */

/* Ajustes Generales de Sección */
.section-padding {
    padding: 80px 0;
}

.text-center { text-align: center; }

.section-title {
    font-size: 2.5rem;
    margin-bottom: 30px;
    color: white;
}
.section-title span {
    color: var(--rojo-carnot);
}

/* --- HERO MINI (Solo para esta página) --- */
.hero-mini {
    justify-content: center; /* Centra el logo */
}
.hero-mini .hero-visual {
    flex: 0 0 auto; /* Evita que se estire */
}

/* --- SECCIÓN ACERCA DE MÍ (Split) --- */
.split-layout {
    display: flex;
    align-items: center;
    gap: 50px;
}

.about-text {
    flex: 1;
}
.about-text p {
    margin-bottom: 15px;
    font-size: 1.1rem;
    color: #ddd;
}

.about-image {
    flex: 1;
    position: relative;
}
.about-image img {
    width: 200px;
    border-radius: 121px;
    box-shadow: 10px 10px 0px var(--rojo-carnot); /* Efecto de marco desplazado */
    filter: grayscale(20%); /* Un toque desaturado artístico */
    transition: 0.3s;
}
.about-image img:hover {
    filter: grayscale(0%);
    transform: translate(-5px, -5px);
    box-shadow: 15px 15px 0px var(--rojo-carnot);
}

/* --- SECCIÓN WORKFLOW (Tarjetas) --- */
.bg-dark {
    background-color: #121212; /* Un poco más oscuro que el fondo normal */
}

.workflow-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.workflow-card {
    background: var(--negro-profundo);
    padding: 30px;
    border-radius: 8px;
    border: 1px solid #333;
    position: relative;
    transition: 0.3s;
}

.workflow-card:hover {
    border-color: var(--rojo-carnot);
    transform: translateY(-5px);
}

.step-number {
    font-family: 'Oswald', sans-serif;
    font-size: 3rem;
    color: rgba(255, 255, 255, 0.05); /* Número gigante casi invisible de fondo */
    position: absolute;
    top: 10px;
    right: 20px;
    font-weight: bold;
}

.workflow-card h3 {
    color: var(--rojo-carnot);
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.workflow-card p {
    color: #ccc;
    font-size: 0.95rem;
}

/* --- RESPONSIVE PARA SOBRE MÍ --- */
@media (max-width: 768px) {
    .split-layout {
        flex-direction: column-reverse; /* Primero la foto, luego el texto en móvil */
    }
    
    .about-image img {
        box-shadow: 5px 5px 0px var(--rojo-carnot);
    }
}