@charset "UTF-8";

/* =========================================
   1. VARIABLES & CONFIGURACIÓN BASE
   ========================================= */
:root {
    --bg-dark: #1a1a1a;
    --bg-darker: #121212;
    --bg-black: #000000;
    --primary: #20a151; /* Tu verde original pero usado estratégicamente */
    --accent: #25d399; /* Verde WhatsApp / Acento brillante */
    --text-white: #ffffff;
    --text-gray: #b3b3b3;
    --font-heading: 'Roboto', sans-serif;
    --font-body: 'Open Sans', sans-serif;
    --transition: all 0.3s ease;
}

html {
    scroll-behavior: smooth;
}

/* Scrollbar Personalizado Premium */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: var(--bg-darker);
}
::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--accent);
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-dark);
    color: var(--text-white);
    line-height: 1.6;
    overflow-x: hidden; /* Evita scroll horizontal no deseado */
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--text-white);
}

a {
    text-decoration: none;
    transition: var(--transition);
}

p {
    color: var(--text-gray);
}

/* Clases de utilidad */
.text-accent { color: var(--accent) !important; }
.bg-accent { background-color: var(--primary); color: white; }
.bg-darker { background-color: var(--bg-darker); }
.bg-black { background-color: var(--bg-black); }
.text-muted-light { color: #aaa; }

.section-padding {
    padding-top: 5rem;
    padding-bottom: 5rem;
}

/* =========================================
   2. HEADER & NAVBAR
   ========================================= */
header {
    background-color: rgba(26, 26, 26, 0.95);
    padding: 1rem 0;
    transition: var(--transition);
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.logo-brand {
    height: 60px;
    width: auto;
    transition: var(--transition);
}

.logo-subtitle {
    font-size: 0.75rem;
    color: var(--text-gray);
    letter-spacing: 1px;
}

/* Estado Scrolled (Manipulado por JS) */
header.scrolled {
    background-color: rgba(0, 0, 0, 0.98);
    padding: 0.5rem 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

header.scrolled .logo-brand {
    height: 45px;
}

/* Links de Navegación */
.nav-link {
    color: var(--text-white) !important;
    font-weight: 600;
    font-size: 0.9rem;
    padding: 0.5rem 1rem !important;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background-color: var(--accent);
    transition: var(--transition);
    transform: translateX(-50%);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 80%;
}

.btn-cta {
    background-color: var(--primary);
    border: none;
    border-radius: 50px;
    padding: 0.5rem 1.5rem;
    font-weight: bold;
}

.btn-cta:hover {
    background-color: var(--accent);
    transform: translateY(-2px);
}

/* =========================================
   3. HERO SECTION (Sobre Mí)
   ========================================= */
.hero-section {
    min-height: 100vh;
    padding-top: 80px; /* Para compensar el navbar fijo */
    background: radial-gradient(circle at 85% 30%, rgba(32, 161, 81, 0.08) 0%, rgba(26, 26, 26, 1) 75%);
}

.profile-img-container {
    position: relative;
    display: inline-block;
}

.profile-img {
    border-radius: 50%;
    max-width: 280px;
    border: 5px solid rgba(255,255,255,0.1);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    transition: var(--transition);
}

.profile-img:hover {
    border-color: var(--accent);
    transform: scale(1.02);
}

/* =========================================
   4. SECCIÓN TRABAJOS (Cards)
   ========================================= */
.section-title {
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.divider {
    height: 3px;
    width: 60px;
    background-color: var(--accent);
    margin-top: 1rem;
}

.project-card {
    background-color: #252525;
    border-radius: 12px;
    overflow: hidden;
    transition: var(--transition);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.2);
}

.project-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    object-position: top;
    transition: transform 0.5s ease;
}

.project-card:hover img {
    transform: scale(1.1);
}

.project-card .card-body {
    background-color: #252525;
    border-top: 1px solid rgba(255,255,255,0.05);
}

.project-card .card-title,
.glass-card .card-title {
    color: var(--text-white);
}

.project-card .card-text {
    color: #d0d0d0 !important;
}

/* =========================================
   5. CONTACTO
   ========================================= */
.btn-whatsapp {
    background-color: #25D366;
    color: white;
    border: none;
    font-weight: 600;
}

.btn-whatsapp:hover {
    background-color: #1ebc57;
    color: white;
}

.social-hover {
    transition: var(--transition);
    display: inline-block;
}

.social-hover:hover {
    color: var(--accent) !important;
    transform: scale(1.2);
}

/* =========================================
   6. RESPONSIVE
   ========================================= */
@media (max-width: 991px) {
    .navbar-collapse {
        background-color: var(--bg-darker);
        padding: 1rem;
        border-radius: 0 0 1rem 1rem;
        box-shadow: 0 10px 20px rgba(0,0,0,0.2);
    }
    
    .hero-section {
        text-align: center;
        padding-top: 120px;
        padding-bottom: 3rem;
    }
    
    .profile-img {
        max-width: 200px;
        margin-top: 2rem;
    }
}

/* =========================================
   7. CLASES DE DISEÑO PREMIUM (Añadidas)
   ========================================= */

/* Insignias de Tecnologías (Badges) */
.tech-badge {
    background-color: rgba(32, 161, 81, 0.1);
    color: var(--accent);
    border: 1px solid rgba(32, 161, 81, 0.25);
    border-radius: 30px;
    padding: 0.2rem 0.65rem;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-block;
    transition: var(--transition);
}

.tech-badge:hover {
    background-color: var(--primary);
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}

/* Caja de Iconos Interactiva para la sección Hero */
.tech-icon-box {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-gray);
    font-size: 1.4rem;
    transition: var(--transition);
    cursor: pointer;
}

.tech-icon-box:hover {
    color: var(--accent);
    background: rgba(37, 211, 153, 0.08);
    border-color: rgba(37, 211, 153, 0.35);
    transform: translateY(-4px) rotate(5deg);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.25);
}

/* Tarjetas de Experimento estilo Glassmorphism */
.glass-card {
    background: rgba(255, 255, 255, 0.02);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    transition: var(--transition);
    height: 100%;
}

.glass-card:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(37, 211, 153, 0.25);
    transform: translateY(-6px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
}

.section-experiments {
    background: radial-gradient(circle at 15% 50%, rgba(37, 211, 153, 0.03) 0%, rgba(18, 18, 18, 1) 75%);
    border-top: 1px solid rgba(255, 255, 255, 0.03);
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

/* Icono de Laboratorio */
.labs-icon {
    color: var(--accent);
    opacity: 0.8;
    transition: var(--transition);
}

.labs-icon:hover {
    transform: scale(1.08) rotate(5deg);
    opacity: 1;
}

/* =========================================
   8. BOTÓN FLOTANTE DE WHATSAPP PREMIUM
   ========================================= */
.whatsapp-float {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 56px;
    height: 56px;
    background-color: #25D366;
    color: white !important;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.whatsapp-float:hover {
    transform: scale(1.1) translateY(-3px);
    background-color: #20ba5a;
    box-shadow: 0 8px 25px rgba(37, 211, 102, 0.3);
}

@media (max-width: 768px) {
    .whatsapp-float {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
        font-size: 1.6rem;
    }
}