/* =========================================
   AÑOS LUZ INFORMÁTICA - PORTFOLIO CSS
   ========================================= */

/* --- Variables CSS --- */
:root {
    /* Paleta de Colores 2026 */
    --bg-color: #0B1220; /* Tono oscuro profundo */
    --bg-color-light: #151F32;
    --primary-color: #007BFF; /* Azul eléctrico */
    --primary-glow: rgba(0, 123, 255, 0.5);
    --secondary-color: #00E5FF; /* Cian */
    --accent-color: #00E676; /* Verde de acento */
    
    /* Textos */
    --text-main: #F8F9FA;
    --text-muted: #ADB5BD;
    
    /* Glassmorphism */
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
    
    /* Tipografía */
    --font-main: 'Poppins', sans-serif;
    
    /* Transiciones */
    --transition-smooth: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    --transition-fast: all 0.2s ease;
}

/* --- Reseteo y Base --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    cursor: none; /* Ocultar cursor por defecto para usar el custom */
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Starry Background Effect */
body::before {
    content: "";
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: -2;
    background-image: 
        radial-gradient(1px 1px at 20px 30px, #eee, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 40px 70px, #fff, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 50px 160px, #ddd, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 90px 40px, #fff, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 130px 80px, #fff, rgba(0,0,0,0)),
        radial-gradient(1px 1px at 160px 120px, #ddd, rgba(0,0,0,0));
    background-repeat: repeat;
    background-size: 200px 200px;
    animation: stars 100s linear infinite;
    opacity: 0.5;
    pointer-events: none;
}

@keyframes stars {
    0% { transform: translateY(0); }
    100% { transform: translateY(-200px); }
}

/* Scrollbar Custom */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: var(--bg-color);
}
::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

/* Utilidades Comunes */
.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

.section-padding {
    padding: 100px 0;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.2;
}

a {
    text-decoration: none;
    color: inherit;
}

li {
    list-style: none;
}

/* --- Scroll Progress Bar --- */
.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
    width: 0%;
    z-index: 9999;
    transition: width 0.1s;
}

/* --- Custom Cursor --- */
.cursor-dot {
    width: 8px;
    height: 8px;
    background-color: var(--secondary-color);
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 99999;
    transform: translate(-50%, -50%);
    transition: width 0.2s, height 0.2s;
}
.cursor-outline {
    width: 40px;
    height: 40px;
    border: 2px solid var(--primary-color);
    position: fixed;
    border-radius: 50%;
    pointer-events: none;
    z-index: 99998;
    transform: translate(-50%, -50%);
    transition: 0.15s ease-out;
}
.cursor-hover .cursor-dot {
    width: 15px;
    height: 15px;
    background-color: var(--accent-color);
}
.cursor-hover .cursor-outline {
    width: 60px;
    height: 60px;
    border-color: var(--accent-color);
    background-color: rgba(0, 230, 118, 0.1);
}

/* --- Glassmorphism Base --- */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    box-shadow: var(--glass-shadow);
    transition: var(--transition-smooth);
}
.glass-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 15px 35px rgba(0, 123, 255, 0.1);
}

/* --- Navegación --- */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px 0;
    z-index: 1000;
    transition: var(--transition-smooth);
}
.header.scrolled {
    padding: 15px 0;
    background: rgba(11, 18, 32, 0.9);
    backdrop-filter: blur(15px);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
}
.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 1px;
}
.logo-accent {
    color: var(--secondary-color);
}
.nav-list {
    display: flex;
    gap: 30px;
}
.nav-link {
    font-size: 1rem;
    font-weight: 500;
    position: relative;
    transition: var(--transition-fast);
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0%;
    height: 2px;
    background: var(--secondary-color);
    transition: var(--transition-smooth);
}
.nav-link:hover {
    color: var(--secondary-color);
}
.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}
.btn-contact-nav {
    background: var(--primary-color);
    padding: 8px 20px;
    border-radius: 20px;
    color: white;
}
.btn-contact-nav::after {
    display: none;
}
.btn-contact-nav:hover {
    background: var(--secondary-color);
    color: var(--bg-color);
    box-shadow: 0 0 15px var(--primary-glow);
}
.mobile-menu-btn {
    display: none;
    font-size: 1.5rem;
}

/* --- Hero Section --- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    padding-top: 80px;
}
.hero-bg-effects {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: -1;
}
.glow-circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.5;
}
.top-left {
    top: -10%; left: -5%;
    width: 400px; height: 400px;
    background: var(--primary-color);
}
.bottom-right {
    bottom: -10%; right: -5%;
    width: 500px; height: 500px;
    background: var(--secondary-color);
    opacity: 0.3;
}
.hero-content {
    max-width: 800px;
}
.greeting {
    display: block;
    font-size: 1.2rem;
    color: var(--secondary-color);
    margin-bottom: 15px;
    font-weight: 500;
    letter-spacing: 2px;
}
.hero-title {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 20px;
}
.highlight {
    background: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}
.hero-subtitle {
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--text-muted);
    margin-bottom: 30px;
}
.hero-text {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 40px;
    max-width: 600px;
}
.hero-buttons {
    display: flex;
    gap: 20px;
}
.btn {
    padding: 12px 30px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 1.1rem;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition-smooth);
    border: 2px solid transparent;
}
.btn-primary {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 0 20px rgba(0, 123, 255, 0.4);
}
.btn-primary:hover {
    background: transparent;
    border-color: var(--primary-color);
    box-shadow: inset 0 0 10px rgba(0, 123, 255, 0.4);
}
.btn-secondary {
    background: transparent;
    border-color: var(--text-main);
    color: var(--text-main);
}
.btn-secondary:hover {
    background: var(--text-main);
    color: var(--bg-color);
}

/* --- Section Headers --- */
.section-header {
    text-align: center;
    margin-bottom: 60px;
}
.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 15px;
}
.separator {
    height: 4px;
    width: 60px;
    background: var(--secondary-color);
    margin: 0 auto 20px auto;
    border-radius: 2px;
}
.section-header p {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* --- About Section --- */
.about-content {
    padding: 40px;
}
.about-text h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--secondary-color);
}
.about-text p {
    margin-bottom: 15px;
    font-size: 1.1rem;
    color: #CFD8DC;
}
.about-highlights {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 30px;
}
.highlight-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
}
.highlight-item i {
    color: var(--accent-color);
    font-size: 1.2rem;
}

/* --- Services Section --- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}
.service-card {
    padding: 30px 25px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.service-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(0, 229, 255, 0.1), transparent);
    opacity: 0;
    transition: var(--transition-smooth);
}
.service-card:hover::before {
    opacity: 1;
}
.service-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 20px;
    transition: var(--transition-smooth);
}
.service-card:hover .service-icon {
    color: var(--secondary-color);
    transform: scale(1.1);
}
.service-card h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
}
.service-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* --- Stats Section --- */
.stats {
    background: linear-gradient(to right, rgba(11, 18, 32, 0.9), rgba(21, 31, 50, 0.9)), url('data:image/svg+xml;utf8,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><rect width="100" height="100" fill="none"/><circle cx="50" cy="50" r="1" fill="rgba(255,255,255,0.1)"/></svg>');
    border-top: 1px solid var(--glass-border);
    border-bottom: 1px solid var(--glass-border);
}
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    text-align: center;
}
.stat-card {
    padding: 20px;
}
.stat-number {
    font-size: 4rem;
    font-weight: 800;
    color: var(--secondary-color);
    line-height: 1;
    margin-bottom: 10px;
    text-shadow: 0 0 15px rgba(0, 229, 255, 0.3);
}
.stat-number::after {
    content: '+';
    font-size: 2rem;
    vertical-align: super;
}
.stat-label {
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--text-main);
}

/* --- Technologies Section --- */
.tech-container {
    overflow: hidden;
    mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}
.tech-scroll {
    display: flex;
    gap: 20px;
    padding: 20px 0;
    width: max-content;
    animation: scrollTech 40s linear infinite;
}
.tech-item-spatial {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-muted);
    backdrop-filter: blur(12px);
    transition: var(--transition-smooth);
}
.tech-item-spatial i {
    font-size: 1.2rem;
    color: var(--primary-color);
}
.tech-item-spatial:hover {
    color: var(--text-main);
    background: rgba(255,255,255,0.08);
    border-color: var(--secondary-color);
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 229, 255, 0.1);
}
.tech-item-spatial:hover i {
    color: var(--secondary-color);
}
@keyframes scrollTech {
    to { transform: translateX(calc(-50% - 10px)); }
}

/* --- Experience (Timeline) --- */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}
.timeline::after {
    content: '';
    position: absolute;
    width: 2px;
    background: var(--glass-border);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -1px;
}
.timeline-item {
    padding: 10px 40px;
    position: relative;
    background-color: inherit;
    width: 50%;
}
.timeline-item:nth-child(odd) {
    left: 0;
}
.timeline-item:nth-child(even) {
    left: 50%;
}
.timeline-dot {
    position: absolute;
    width: 20px;
    height: 20px;
    right: -10px;
    background-color: var(--primary-color);
    border: 4px solid var(--bg-color);
    top: 15px;
    border-radius: 50%;
    z-index: 1;
    box-shadow: 0 0 10px var(--primary-glow);
}
.timeline-item:nth-child(even) .timeline-dot {
    left: -10px;
}
.timeline-content {
    padding: 25px;
}
.timeline-content h3 {
    font-size: 1.3rem;
    color: var(--secondary-color);
    margin-bottom: 5px;
}
.timeline-content h4 {
    font-size: 1.1rem;
    color: var(--text-main);
    margin-bottom: 10px;
}
.timeline-date {
    display: inline-block;
    padding: 5px 15px;
    background: rgba(255,255,255,0.05);
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--accent-color);
    margin-bottom: 15px;
}
.timeline-content p:last-child {
    font-size: 0.95rem;
    color: var(--text-muted);
}

/* --- Contact Section --- */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 40px;
}
.contact-info {
    padding: 40px;
}
.contact-info h3 {
    font-size: 1.5rem;
    margin-bottom: 25px;
    color: var(--secondary-color);
}
.contact-list li {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    font-size: 1.05rem;
}
.contact-list i {
    font-size: 1.5rem;
    color: var(--primary-color);
}
.social-links {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}
.social-link {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--glass-border);
    transition: var(--transition-smooth);
    font-size: 1.2rem;
}
.social-link:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-3px);
}
.contact-form-container {
    padding: 40px;
}
.form-group {
    margin-bottom: 20px;
}
.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}
.form-group input, .form-group textarea {
    width: 100%;
    padding: 15px;
    background: rgba(0,0,0,0.2);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    color: var(--text-main);
    font-family: var(--font-main);
    font-size: 1rem;
    transition: var(--transition-fast);
}
.form-group input:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
    background: rgba(0,0,0,0.4);
    box-shadow: 0 0 10px rgba(0, 229, 255, 0.1);
}
.btn-submit {
    width: 100%;
    justify-content: center;
    border: none;
    cursor: pointer; /* Solo para el click interno, aunque el custom lo sobreescribe en UI */
}

/* --- Footer --- */
.footer {
    padding: 30px 0;
    text-align: center;
    border-top: 1px solid var(--glass-border);
    background: var(--bg-color-light);
}
.footer-logo {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--secondary-color);
}
.footer-copy {
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* --- Botones Flotantes --- */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--bg-color-light);
    border: 1px solid var(--glass-border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--text-main);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-smooth);
    box-shadow: var(--glass-shadow);
}
.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}
.back-to-top:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-5px);
}

.whatsapp-float {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 60px;
    height: 60px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
    z-index: 999;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.4);
    transition: var(--transition-smooth);
}
.whatsapp-float:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.6);
}

/* --- Animaciones CSS (Reveal) --- */
.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}
.reveal.active {
    opacity: 1;
    transform: translateY(0);
}
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }

/* --- Reviews Section --- */
.review-container {
    overflow: hidden;
    mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    padding: 20px 0;
}
.review-scroll {
    display: flex;
    gap: 30px;
    width: max-content;
    animation: scrollReview 30s linear infinite;
}
.review-scroll:hover {
    animation-play-state: paused;
}
.review-card {
    width: 350px;
    padding: 25px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    white-space: normal;
}
.review-header {
    display: flex;
    align-items: center;
    gap: 15px;
}
.review-avatar {
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
}
.review-info h4 {
    font-size: 1.1rem;
    color: var(--secondary-color);
    margin-bottom: 2px;
}
.review-info span {
    font-size: 0.85rem;
    color: var(--text-muted);
}
.review-text {
    font-size: 0.95rem;
    font-style: italic;
    color: #E0E0E0;
    line-height: 1.5;
}

@keyframes scrollReview {
    to { transform: translateX(calc(-50% - 15px)); }
}

/* --- Modal --- */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(5px);
    align-items: center;
    justify-content: center;
}
.modal.active {
    display: flex;
}
.modal-content {
    width: 90%;
    max-width: 500px;
    padding: 40px;
    position: relative;
    animation: modalPop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 2rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: var(--transition-fast);
}
.close-modal:hover {
    color: var(--secondary-color);
}
.modal-content h3 {
    font-size: 1.8rem;
    margin-bottom: 10px;
    color: var(--secondary-color);
}

@keyframes modalPop {
    0% { transform: scale(0.8); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}


/* --- Responsive Design --- */
@media (max-width: 992px) {
    .hero-title {
        font-size: 3rem;
    }
    .timeline::after {
        left: 31px;
    }
    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 25px;
    }
    .timeline-item:nth-child(even) {
        left: 0%;
    }
    .timeline-dot {
        left: 21px !important;
    }
    .contact-wrapper {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    /* Desactivar custom cursor en móviles */
    .cursor-dot, .cursor-outline {
        display: none;
    }
    * { cursor: auto; }
    
    .nav-list {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        flex-direction: column;
        background: var(--bg-color-light);
        padding: 20px;
        gap: 15px;
        text-align: center;
        border-bottom: 1px solid var(--glass-border);
        clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
        transition: clip-path 0.4s ease-out;
    }
    .nav-list.active {
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
    }
    .mobile-menu-btn {
        display: block;
    }
    
    .hero-title {
        font-size: 2.2rem;
    }
    .hero-subtitle {
        font-size: 1.1rem;
    }
    .hero-buttons {
        flex-direction: column;
    }
    .stats-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .whatsapp-float {
        bottom: 90px; /* Para no solaparse con back to top en móviles */
        left: auto;
        right: 25px;
        width: 50px;
        height: 50px;
        font-size: 1.6rem;
    }
    .back-to-top {
        right: 25px;
        bottom: 25px;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    .section-header h2 {
        font-size: 2rem;
    }
}
