/* Variables */
:root {
    --primary-color: #2c3e50;
    --secondary-color: #e74c3c;
    --accent-color: #3498db;
    --dark-color: #1a252f;
    --light-color: #ecf0f1;
    --text-color: #333;
    --text-light: #7f8c8d;
    --industrial-gray: #95a5a6;
    --industrial-dark: #34495e;
    --industrial-accent: #f39c12;
}

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #f5f5f5;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 0.75rem;
}

a {
    text-decoration: none;
    color: var(--accent-color);
    transition: all 0.3s ease;
}

a:hover {
    color: var(--secondary-color);
}

img {
    max-width: 100%;
    height: auto;
}

ul {
    list-style: none;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section-industrial {
    padding: 80px 0;
    position: relative;
}

.dark-bg {
    background-color: var(--dark-color);
    color: var(--light-color);
}

.section-title {
    text-align: center;
    margin-bottom: 60px;
    font-size: 2.5rem;
    position: relative;
    color: var(--primary-color);
}

.dark-bg .section-title {
    color: var(--light-color);
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background-color: var(--industrial-accent);
    margin: 20px auto;
}

.btn-industrial {
    display: inline-block;
    padding: 12px 30px;
    background-color: var(--industrial-accent);
    color: white;
    border: none;
    border-radius: 4px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.btn-industrial:hover {
    background-color: #e67e22;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 6px 8px rgba(0, 0, 0, 0.15);
}

/* Hero con video background */
.industrial-header {
    position: relative;
    height: 100vh;
    min-height: 700px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    margin-bottom: 80px;
}

.video-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -2;
    overflow: hidden;
}

.header-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
    z-index: -1;
}

.header-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 33, 66, 0.37) 0%, rgba(39, 74, 122, 0.322) 100%);
    z-index: -1;
}

/* Partículas flotantes */
.particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
}

.particle {
    position: absolute;
    background: rgba(100, 123, 255, 0.6);
    border-radius: 50%;
    pointer-events: none;
}

/* Logo con efecto parallax */
.logo-container {
    width: 200px;
    height: 200px;
    margin: 0 auto 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.5s ease-out;
    will-change: transform;
}

/* Estilos para el logo en el navbar */
.logo-img {
    height: 50px;
    width: auto;
    transition: all 0.3s ease;
}

/* Estilos para el logo en el hero */
.logo-hero {
    height: 100px;
    width: auto;
    animation: pulse 2s infinite;
}

/* Opcional: Si quieres mantener alguna animación */
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.hero-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 0 20px;
    position: relative;
    z-index: 1;
    margin-top: 100px;
}

.hero-content h2 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    text-transform: uppercase;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-content p {
    font-size: 1.3rem;
    max-width: 700px;
    margin-bottom: 40px;
    color: white;
    opacity: 0.9;
}

.typewriter {
    display: inline-block;
    position: relative;
    color: var(--accent-color);
}

.typewriter::after {
    content: "|";
    position: absolute;
    right: -10px;
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0) translateX(-50%); }
    40% { transform: translateY(-20px) translateX(-50%); }
    60% { transform: translateY(-10px) translateX(-50%); }
}

/* Header Navigation */
.industrial-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 20px 0;
    z-index: 1000;
    transition: all 0.3s ease;
    background-color: rgba(26, 37, 47, 0.562);
}

.industrial-nav.scrolled {
    background-color: rgba(26, 37, 47, 0.95);
    padding: 15px 0;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.logo {
    display: flex;
    align-items: center;
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
}

.nav-links {
    display: flex;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    color: white;
    font-weight: 600;
    position: relative;
    padding: 5px 0;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--industrial-accent);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    font-size: 1.5rem;
    color: white;
    cursor: pointer;
}

/* About Section - Mejorado para responsive */
.about-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    position: relative;
}

.profile-info {
    position: relative;
    padding: 40px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.profile-info h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.profile-info h3 {
    font-size: 1.5rem;
    color: var(--industrial-accent);
    margin-bottom: 30px;
}

.profile-info p {
    margin-bottom: 30px;
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--text-color);
}

.profile-badge {
    display: inline-block;
    background-color: var(--industrial-accent);
    color: white;
    padding: 8px 20px;
    border-radius: 30px;
    margin-bottom: 20px;
    font-weight: 600;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.profile-badge i {
    margin-right: 10px;
}

.personal-info {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin-top: 40px;
    text-align: center;
}

.info-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 15px;
    background-color: rgba(243, 156, 18, 0.1);
    border-radius: 8px;
    transition: all 0.3s ease;
    width: 100%;
    max-width: 100%;
    min-width: auto;
    margin-bottom: 15px;
    word-wrap: break-word;
}

.info-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.info-item i {
    font-size: 1.5rem;
    color: var(--industrial-accent);
}

/* Simplified About Section */
.simplified-profile {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.simplified-profile h3 {
    font-size: 2rem;
    color: var(--primary-color);
    margin: 20px 0 10px;
}

.profession {
    color: var(--industrial-accent);
    font-size: 1.2rem;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.about-text {
    text-align: left;
    margin: 30px 0;
}

.about-text p {
    margin-bottom: 15px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.about-text i {
    color: var(--industrial-accent);
    margin-top: 3px;
}

.contact-icons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 30px;
}

.contact-icons a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: rgba(243, 156, 18, 0.1);
    border-radius: 30px;
    color: var(--text-color);
    transition: all 0.3s ease;
}

.contact-icons a:hover {
    background: var(--industrial-accent);
    color: white;
    transform: translateY(-3px);
}

/* Services Section */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card {
    background-color: white;
    border-radius: 10px;
    padding: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    text-align: center;
    border-top: 4px solid var(--industrial-accent);
}

.dark-bg .service-card {
    background-color: var(--industrial-dark);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.service-icon {
    width: 80px;
    height: 80px;
    background-color: rgba(243, 156, 18, 0.1);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 20px;
    font-size: 2rem;
    color: var(--industrial-accent);
}

.service-card h3 {
    margin-bottom: 15px;
    font-size: 1.5rem;
}

/* Projects Section */
.projects-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 40px;
}

.filter-btn {
    padding: 8px 20px;
    background-color: transparent;
    border: 2px solid var(--industrial-accent);
    color: var(--industrial-accent);
    border-radius: 30px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.filter-btn.active, .filter-btn:hover {
    background-color: var(--industrial-accent);
    color: white;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
}

.project-card {
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    position: relative;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.project-image {
    height: 250px;
    overflow: hidden;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.project-card:hover .project-image img {
    transform: scale(1.1);
}

.project-info {
    padding: 20px;
}

.project-category {
    display: inline-block;
    padding: 5px 15px;
    background-color: var(--industrial-accent);
    color: white;
    border-radius: 30px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 10px;
}

.project-title {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.project-client {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.project-link {
    display: inline-flex;
    align-items: center;
    color: var(--industrial-accent);
    font-weight: 600;
}

.project-link i {
    margin-left: 5px;
    transition: transform 0.3s ease;
}

.project-link:hover i {
    transform: translateX(5px);
}

/* Improved Clients Section */
.clients-slider {
    display: flex;
    flex-wrap: nowrap;
    overflow: hidden;
    width: 100%;
    padding: 30px 0;
    position: relative;
}

.clients-slider::before,
.clients-slider::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 100px;
    z-index: 2;
}

.clients-slider::before {
    left: 0;
    background: linear-gradient(to right, var(--dark-color), transparent);
}

.clients-slider::after {
    right: 0;
    background: linear-gradient(to left, var(--dark-color), transparent);
}

.clients-slider-inner {
    display: flex;
    animation: slide 30s linear infinite;
}

.client-logo {
    flex: 0 0 auto;
    padding: 15px 30px;
    margin: 0 15px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    font-weight: 600;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.client-logo:hover {
    background-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-5px);
}

@keyframes slide {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* Contact Section */
.contact-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 50px;
    margin-top: 40px;
}

.contact-info {
    padding: 30px;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.contact-info h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--primary-color);
}

.contact-item {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.contact-item i {
    font-size: 1.2rem;
    color: var(--industrial-accent);
    margin-right: 15px;
    width: 30px;
    text-align: center;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

.social-links a {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background-color: var(--industrial-accent);
    color: white;
    border-radius: 50%;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

.contact-form {
    background-color: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--industrial-accent);
    box-shadow: 0 0 0 3px rgba(243, 156, 18, 0.2);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* Footer */
.industrial-footer {
    background-color: var(--dark-color);
    color: var(--light-color);
    padding: 60px 0 0;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}

.footer-logo {
    margin-bottom: 20px;
}

.footer-logo h3 {
    color: white;
    margin-bottom: 10px;
}

.footer-logo p {
    color: var(--industrial-gray);
}

.footer-links h4,
.footer-contact h4 {
    color: white;
    margin-bottom: 20px;
    font-size: 1.3rem;
}

.footer-links ul li {
    margin-bottom: 10px;
}

.footer-links a {
    color: var(--industrial-gray);
    transition: all 0.3s ease;
}

.footer-links a:hover {
    color: var(--industrial-accent);
    padding-left: 5px;
}

.footer-contact p {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    color: var(--industrial-gray);
}

.footer-contact i {
    margin-right: 10px;
    color: var(--industrial-accent);
    width: 20px;
    text-align: center;
}

.footer-bottom {
    text-align: center;
    padding: 20px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--industrial-gray);
    font-size: 0.9rem;
}

.footer-bottom p {
    margin-bottom: 10px;
}

/* Responsive Styles */
@media (max-width: 1200px) {
    .container {
        padding: 0 30px;
    }
}

@media (max-width: 992px) {
    .section-industrial {
        padding: 70px 0;
    }
    
    .section-title {
        font-size: 2.2rem;
        margin-bottom: 50px;
    }
    
    .hero-content h2 {
        font-size: 3rem;
    }
    
    .profile-info {
        padding: 35px;
    }
    
    .profile-info h2 {
        font-size: 2.2rem;
    }
}

@media (max-width: 768px) {
    @media (max-width: 768px) {
        .video-container {
            /* En móviles, muestra una imagen de fondo como fallback */
            background: url('../img/background/mobile-fallback.jpg') no-repeat center center/cover;
        }
        
        .header-video {
            /* Intenta mostrar el video pero con controles para móviles */
            display: block;
            /* Asegúrate de que el video se vea bien en móviles */
            object-fit: cover;
            width: 100%;
            height: 100%;
        }
    }
    
    .industrial-header {
        min-height: 600px;
        margin-bottom: 60px;
    }
    
    .section-industrial {
        padding: 60px 0;
    }
    
    .section-title {
        font-size: 2rem;
        margin-bottom: 40px;
    }
    
    .hero-content h2 {
        font-size: 2.2rem;
        padding: 0 15px;
    }
    
    .hero-content p {
        font-size: 1.1rem;
        padding: 0 15px;
    }
    
    .profile-info {
        padding: 30px 20px;
    }
    
    .profile-info h2 {
        font-size: 2rem;
    }
    
    .profile-info h3 {
        font-size: 1.3rem;
    }
    
    .service-card {
        padding: 25px;
    }
    
    .service-icon {
        width: 70px;
        height: 70px;
        font-size: 1.8rem;
    }
    
    @media (max-width: 768px) {
        .menu-toggle {
            display: block;
            z-index: 1001;
            cursor: pointer;
        }
    
        .nav-links {
            position: fixed;
            top: 80px;
            left: -100%;
            width: 100%;
            height: calc(100vh - 80px);
            background-color: var(--dark-color);
            flex-direction: column;
            align-items: center;
            padding: 40px 0;
            transition: all 0.5s ease;
            z-index: 1000;
        }
    
        .nav-links.active {
            left: 0;
        }
    
        .nav-links li {
            margin: 15px 0;
        }
        
        /* Asegúrate que el icono cambie correctamente */
        .menu-toggle i {
            transition: all 0.3s ease;
            font-size: 1.8rem;
        }
    }
    
    .projects-grid {
        grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    }
    
    .project-image {
        height: 220px;
    }
}

@media (max-width: 576px) {
    .industrial-header {
        min-height: 500px;
    }
    
    .hero-content h2 {
        font-size: 1.8rem;
    }
    
    .hero-content p {
        font-size: 1rem;
    }
    
    .btn-industrial {
        padding: 10px 25px;
        font-size: 0.9rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .profile-info {
        padding: 25px 15px;
    }
    
    .profile-info h2 {
        font-size: 1.8rem;
    }
    
    .profile-info h3 {
        font-size: 1.2rem;
    }
    
    .profile-info p {
        font-size: 1rem;
    }
    
    .info-item {
        padding: 12px;
    }
    
    .info-item p {
        font-size: 0.9rem;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .filter-btn {
        padding: 6px 15px;
        font-size: 0.9rem;
    }
    
    .contact-container {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .contact-info, .contact-form {
        padding: 25px;
    }
}

@media (max-width: 480px) {
    .nav-container {
        padding: 0 20px;
    }
    
    .logo-img {
        height: 40px;
    }
    
    .hero-content h2 {
        font-size: 1.6rem;
    }
    
    .section-title {
        font-size: 1.6rem;
    }
    
    .profile-info h2 {
        font-size: 1.5rem;
    }
    
    .profile-badge {
        font-size: 0.9rem;
    }
    
    .service-card {
        padding: 20px;
    }
    
    .service-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .service-card h3 {
        font-size: 1.3rem;
    }
    
    .client-logo {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}

/* Animations */
@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

.animate-float {
    animation: float 6s ease-in-out infinite;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
    animation: fadeIn 1s ease-out forwards;
}

.delay-1 { animation-delay: 0.3s; }
.delay-2 { animation-delay: 0.6s; }
.delay-3 { animation-delay: 0.9s; }
.delay-4 { animation-delay: 1.2s; }

/* Typing Effect */
.typing-effect {
    overflow: hidden;
    white-space: nowrap;
    border-right: 3px solid var(--industrial-accent);
    animation: typing 3.5s steps(40, end), blink-caret 0.75s step-end infinite;
    color:white;
    border-right-color: white;
}

@keyframes typing {
    from { width: 0; }
    to { width: 100%; }
}

@keyframes blink-caret {
    from, to { border-color: transparent; }
    50% { border-color: var(--industrial-accent); }
}