:root {
    --bg-dark: #080808;
    --bg-card: #121212;
    --bg-input: #161616;
    --accent: #c6a678;       /* Dorado/Beige */
    --accent-hover: #b0936a;
    --text-white: #ffffff;
    --text-gray: #888888;
    --border-color: #222222;
}

* {
    margin: 0;
    font-family: 'Manrope', sans-serif;
    padding: 0;
    box-sizing: border-box;
    outline: none;
}

/* REGLA GLOBAL PARA PÁRRAFOS */
p {
    font-weight: 600;  
    font-size: 1rem;   
    line-height: 1.3; 
    opacity: 0.9;      
}

body {
    background-color: var(--bg-dark);
    color: var(--text-white);
    background-image: linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 12.5% 100%; 
    min-height: 100vh;
    overflow-x: hidden;
    cursor: none; 
}

/* --- PRELOADER --- */
#preloader {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: #080808;
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.8s ease; 
}

.preloader-logo {
    width: 80px;
    animation: pulse 1.0s infinite; 
}

/* --- CURSOR PERSONALIZADO --- */
.custom-cursor {
    position: fixed;
    width: 20px;
    height: 20px;
    border: 2px solid var(--accent);
    border-radius: 50%;
    pointer-events: none; 
    transform: translate(-50%, -50%);
    transition: width 0.2s, height 0.2s, background-color 0.2s;
    z-index: 9999;
    mix-blend-mode: difference; 
}

.custom-cursor.hovered {
    width: 50px;
    height: 50px;
    background-color: rgba(198, 166, 120, 0.2);
    border-color: transparent;
}

a, button, input, textarea, .btn {
    cursor: none;
}

/* --- CLASES UTILITARIAS --- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.highlight { color: var(--accent); }

a { text-decoration: none; }

/* --- NAVBAR --- */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 0; 
    margin-bottom: 2rem;
}

.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo-img {
    height: 55px; 
    width: auto;  
    transition: transform 0.3s ease;
}

.logo-img:hover {
    transform: scale(1.05); 
}

.btn-contact-nav {
    background-color: var(--accent);
    color: #1a1a1a;
    padding: 0.6rem 1.2rem;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: 0.3s;
}
.btn-contact-nav:hover { background-color: var(--accent-hover); }

/* --- HERO SECTION --- */
.hero {
    display: grid;
    grid-template-columns: 1.2fr 1fr 0.8fr; 
    align-items: center;
    min-height: 600px; 
    margin-bottom: 6rem;
}


.hero-text h3 {
    font-size: 1.5rem;
    color: #555;
    font-weight: 500;
    margin-bottom: 0.5rem;
}

.hero-text h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.hero-text p {
    color: var(--text-gray);
    line-height: 1.6;
    margin-bottom: 2.5rem;
    max-width: 400px;
    font-size: 1rem;
}

.hero-buttons {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.btn-primary {
    background-color: var(--accent);
    color: #1a1a1a;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: transform 0.3s, background 0.3s;
    border: none;
    cursor: pointer;
}
.btn-primary:hover { transform: translateY(-2px); background-color: var(--accent-hover); }

.btn-secondary {
    color: #fff;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: color 0.3s;
}
.btn-secondary:hover { color: var(--accent); }

/* --- HERO IMAGEN --- */

.hero-image-wrapper {
    position: relative;
    width: 100%;            /* Ahora ocupa el espacio disponible */
    max-width: 450px;       /* Tamaño máximo para que no se vea gigante */
    height: auto;           /* La altura se ajusta a la foto */
    margin: 0 auto;         /* Centrado */
    
    /* --- QUITAMOS EL CÍRCULO BEIGE --- */
    background-color: transparent; 
    border: none; 
    border-radius: 0;       
    box-shadow: none;       /* Quitamos la sombra de la caja */
    overflow: visible;      /* Permitimos que la foto se vea completa */
    
    /* Alineación */
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Ocultamos formas viejas por si acaso */
.bg-shape { display: none; }

.profile-img {
    width: 100%;            /* La foto ocupa el ancho del wrapper */
    height: auto;           /* Mantiene proporción */
    object-fit: contain;
    
    /* Reseteamos estilos anteriores */
    border-radius: 0;
    border: none;
    mask-image: none;
    bottom: 0;
    
    /* AGREGAMOS SOMBRA A LA SILUETA (Opcional pero recomendado) */
    /* Esto le da profundidad a tu cuerpo sobre el fondo negro */
    filter: drop-shadow(0 0 20px rgba(0,0,0,0.5));
}

/* --- STATS CARD --- */
.stats-card {
    background-color: #0c0c0c;
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2.5rem 2rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    width: 100%;
    max-width: 280px;
    justify-self: end; 
    animation: slideInRight 1s ease-out forwards;
    opacity: 0; 
    transform: translateX(50px); 
}

@keyframes slideInRight {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.stat-item h4 {
    font-size: 2rem;
    color: var(--accent);
    margin-bottom: 0.2rem;
    font-weight: 400;
}

.stat-item p {
    color: var(--text-gray);
    font-size: 0.9rem;
}

.stat-separator {
    height: 1px;
    background-color: #222;
    width: 100%;
}

/* --- SECCIONES GENERALES --- */
.section-title { text-align: center; font-size: 2.5rem; margin-bottom: 3rem; margin-top: 4rem; }

/* Grid Servicios */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 1.5rem;
    margin-bottom: 6rem;
}
.service-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    display: flex; align-items: center; gap: 1.5rem; transition: all 0.3s ease;
}
.service-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.service-num { font-size: 1.5rem; color: var(--accent); opacity: 0.8; font-variant-numeric: tabular-nums; }
.service-content h3 { font-size: 1.1rem; margin-bottom: 0.3rem; }
.service-content p { font-size: 0.85rem; color: var(--text-gray); }
.arrow-icon { width: 40px; height: 40px; background-color: #1a1a1a; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--text-gray); transition: 0.3s; }
.service-card:hover .arrow-icon { background-color: var(--accent); color: #000; }

/* Skills */
.skills-section-wrapper {
    background-color: #0c0c0c;
    box-shadow: 0 0 40px rgba(198, 166, 120, 0.15); 
    border-radius: 20px; padding: 4rem;
    display: grid; grid-template-columns: 1fr 1.2fr; gap: 4rem; align-items: center;
    border: 1px solid var(--accent); margin-bottom: 6rem;
    transition: box-shadow 0.3s ease;
}

.skills-section-wrapper:hover {
    box-shadow: 0 0 60px rgba(198, 166, 120, 0.3);
}

.skills-text h2 { font-size: 2.5rem; margin-bottom: 1.5rem; }
.skills-text p { color: var(--text-gray); line-height: 1.6; margin-bottom: 2rem; }
.tools-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; }
.tool-card {
    background-color: #161616; border: 1px solid #252525; border-radius: 12px;
    padding: 1.5rem 0.5rem; display: flex; flex-direction: column; align-items: center;
    text-align: center; transition: 0.3s;
}
.tool-card:hover { background-color: #1f1f1f; border-color: #444; }
.percentage-pill { background-color: #222; color: var(--text-gray); font-size: 0.75rem; padding: 4px 12px; border-radius: 12px; font-weight: 600; }
.ps { color: #31a8ff; } .ai { color: #ff9a00; } .ae { color: #9999ff; } .pr { color: #db96ff; }
.xd { color: #ff61f6; } .wp { color: #21759b; } .firefly { color: #ff0000; } .ai-gen { color: #fff; }

/* Contacto */
.contact-wrapper {
    display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 4rem; padding-bottom: 4rem;
}
.contact-info h2 { font-size: 3rem; margin-bottom: 1.5rem; }
.benefits-list { list-style: none; display: flex; flex-direction: column; gap: 1rem; }
.benefits-list li { display: flex; align-items: center; gap: 1rem; color: #ddd; font-weight: 600; font-size: 1rem; }
.check-icon { color: var(--accent); font-size: 1.4rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; margin-bottom: 1.5rem; }
.input-group { display: flex; flex-direction: column; gap: 0.5rem; margin-bottom: 1.5rem; }
.input-group label { color: #fff; font-weight: 700; font-size: 1rem; }
.input-group label span { color: var(--accent); }
.input-field {
    background-color: var(--bg-input); border: 1px solid #333; padding: 1rem;
    border-radius: 8px; color: #fff; font-size: 1rem; transition: border-color 0.3s; width: 100%;
}
.input-field:focus { border-color: var(--accent); }
textarea.input-field { resize: none; height: 150px; }


/* --- NAVEGACIÓN "SIGUIENTE PROYECTO" (CENTRADO PERFECTO) --- */
.next-project-section {
    margin-top: 4rem;
    padding: 6rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    
    /* ESTO ASEGURA EL CENTRADO DE LOS BLOQUES */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    
    position: relative;
    overflow: hidden;
}

.next-label {
    display: block;
    font-size: 0.9rem;
    color: var(--text-gray);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 1rem;
    text-align: center; /* Asegura que el texto interno esté centrado */
}

.next-link {
    /* CAMBIO CLAVE: Usamos relative para que la flecha flote respecto a esto */
    position: relative; 
    display: inline-block; /* Se ajusta al tamaño exacto del texto */
    text-decoration: none;
    cursor: none; /* Mantiene tu cursor personalizado */
}

.next-title {
    font-size: 4rem;
    font-weight: 800;
    color: #fff;
    margin: 0;
    transition: color 0.3s ease;
    line-height: 1;
    text-align: center;
}

.next-arrow {
    font-size: 3rem;
    color: var(--accent);
    
    /* CAMBIO CLAVE: Posición absoluta para no empujar el texto */
    position: absolute;
    top: 50%;           /* Centrado verticalmente */
    right: -60px;       /* Lo ponemos 60px a la derecha del texto */
    
    /* Animación de entrada */
    transform: translateY(-50%) translateX(-20px); 
    opacity: 0; 
    transition: all 0.3s ease;
}

/* EFECTO HOVER */
.next-link:hover .next-title {
    color: var(--accent);
}

.next-link:hover .next-arrow {
    opacity: 1;
    /* Al hacer hover, se mueve a su posición final */
    transform: translateY(-50%) translateX(0); 
}

/* Responsive para móvil */
@media (max-width: 768px) {
    .next-title { font-size: 2.5rem; }
    
    /* En móvil ajustamos la flecha para que no se salga de la pantalla */
    .next-arrow { 
        font-size: 2rem; 
        position: relative; /* En móvil sí dejamos que ocupe espacio */
        right: auto; 
        top: auto;
        display: inline-block;
        opacity: 1; 
        transform: none; 
        margin-left: 10px;
    }
    
    /* Volvemos a flex en móvil para alinear texto y flecha */
    .next-link {
        display: flex;
        align-items: center;
        justify-content: center;
    }
}




/* Responsive */
@media (max-width: 1024px) {
    .hero { grid-template-columns: 1fr; text-align: center; gap: 3rem; margin-top: 2rem; }
    .hero-buttons { justify-content: center; }
    .hero-text p { margin: 0 auto 2.5rem auto; }
    .stats-card { justify-self: center; max-width: 100%; flex-direction: row; justify-content: space-around; }
    .stat-separator { width: 1px; height: 50px; }
    .hero-image-wrapper { order: -1; margin-bottom: 1rem; } 
}

@media (max-width: 900px) {
    .skills-section-wrapper, .contact-wrapper { grid-template-columns: 1fr; padding: 2rem 0; gap: 2rem; }
    .tools-grid { grid-template-columns: repeat(2, 1fr); }
    .services-grid { grid-template-columns: 1fr; }
    .stat-separator { display: none; }
    .stats-card { flex-direction: column; gap: 1rem; text-align: center; }
}

@media (max-width: 600px) {
    .form-row { grid-template-columns: 1fr; margin-bottom: 0; }
    .hero-text h1 { font-size: 2.5rem; }
}