/* --- ESTILOS GENERALES --- */
:root {
    --white: #ffffff;
    --black: #000000;
    --gray-50: #fafafa;
    --gray-100: #f5f5f5;
    --gray-200: #e5e5e5;
    --gray-300: #d4d4d4;
    --gray-400: #a3a3a3;
    --gray-500: #737373;
    --gray-600: #525252;
    --gray-700: #404040;
    --gray-800: #262626;
    --gray-900: #171717;
    --font-heading: 'Inter', sans-serif;
    --font-body: 'Inter', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background-color: var(--black);
    color: var(--white);
    overflow-x: hidden;
}

/* --- NAVEGACIN --- */
nav {
    position: fixed;
    width: 100%;
    padding: 30px 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--gray-200);
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 900;
    color: var(--black);
    letter-spacing: 2px;
}

.nav-links a {
    color: var(--black);
    text-decoration: none;
    margin-left: 40px;
    font-weight: 500;
    font-family: var(--font-heading);
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--black);
    transition: width 0.3s ease;
}

.nav-links a:hover::after {
    width: 100%;
}

/* --- HERO SECTION --- */
.hero {
    height: 100vh;
    width: 100%;
    background-color: var(--white);
    background-image: url('images/hero.jpg');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.6) 0%, rgba(20, 20, 40, 0.4) 100%);
    pointer-events: none;
}

.hero-content {
    max-width: 1000px;
    padding: 20px;
    position: relative;
    z-index: 2;
}

.hero h1 {
    font-family: var(--font-heading);
    font-size: 4.5rem;
    line-height: 1.1;
    font-weight: 900;
    margin-bottom: 24px;
    color: var(--white);
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.5);
    animation: fadeInUp 1s ease-out;
}

.hero h1 span {
    display: block;
    font-size: 2rem;
    font-weight: 300;
    letter-spacing: 5px;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 10px;
}

.hero p {
    font-size: 1.4rem;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 40px;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.5);
    animation: fadeInUp 1s ease-out 0.2s;
    animation-fill-mode: both;
}

.btn-main {
    padding: 18px 50px;
    background-color: transparent;
    border: 2px solid var(--white);
    color: var(--white);
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    animation: fadeInUp 1s ease-out 0.4s;
    animation-fill-mode: both;
}

.btn-main:hover {
    background-color: var(--white);
    color: var(--black);
    transform: translateY(-2px);
    box-shadow: 0 8px 12px rgba(255, 255, 255, 0.4);
}

/* --- SECCIN DE DIVISIN CON IMAGEN --- */
.split-section {
    display: flex;
    height: 600px;
    width: 100%;
}

.split-image {
    flex: 1;
    background-size: cover;
    background-position: center;
    position: relative;
    transition: transform 0.3s ease;
}

.split-image:hover {
    transform: scale(1.05);
}

/* Imagen de Unity/VR */
.img-unity {
    background-image: url('images/split.jpg');
}

.split-content {
    flex: 1;
    background-color: var(--white);
    padding: 80px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.section-tag {
    color: var(--gray-600);
    font-weight: 600;
    font-family: var(--font-heading);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 15px;
    display: block;
    font-size: 0.875rem;
}

.section-title {
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 20px;
    color: var(--black);
}

.split-content p {
    font-size: 1.2rem;
    color: var(--gray-600);
    margin-bottom: 30px;
    line-height: 1.6;
}

.split-content a {
    color: var(--black);
    text-decoration: none;
    font-weight: 600;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.split-content a:hover {
    gap: 12px;
}

/* --- CARACTERISTICAS GRID CON ICONOS --- */
.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background-color: var(--gray-200);
}

.feature-box {
    padding: 50px 30px;
    background-color: var(--white);
    text-align: center;
    transition: all 0.3s ease;
}

.feature-box:hover {
    background-color: var(--gray-50);
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: var(--black);
    transition: transform 0.3s ease;
}

.feature-box:hover .feature-icon {
    transform: translateY(-5px);
}

.feature-box h3 {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--black);
}

.feature-box p {
    color: var(--gray-600);
    font-size: 0.95rem;
}

/* --- SECCIÓN CON FILTRO GRIS (VR LABORATORIO) --- */
.vr-lab-section {
    height: 600px;
    background-image: url('images/vr-lab.jpg');
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    filter: grayscale(70%) brightness(0.8);
    transition: filter 0.5s ease;
}

.vr-lab-section:hover {
    filter: grayscale(0%) brightness(1);
}

.vr-lab-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.7) 0%, rgba(20, 20, 40, 0.5) 100%);
    pointer-events: none;
}

.vr-lab-text {
    position: relative;
    text-align: center;
    max-width: 800px;
    padding: 0 20px;
    z-index: 2;
}

.vr-lab-text .section-tag {
    color: var(--white);
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
}

.vr-lab-text h2 {
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 800;
    color: var(--white);
    margin: 20px 0;
    text-shadow: 3px 3px 10px rgba(0, 0, 0, 0.9);
}

.vr-lab-text p {
    font-size: 1.3rem;
    color: rgba(255, 255, 255, 0.95);
    margin-top: 20px;
    line-height: 1.6;
    text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.8);
}

/* --- CURSOS LISTADO --- */
.courses-section {
    padding: 100px 5%;
    background-color: var(--black);
}

.courses-section .section-tag {
    color: var(--gray-600);
}

.courses-section .section-title {
    color: var(--white);
}

.courses-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.course-card {
    position: relative;
    height: 400px;
    overflow: hidden;
    border: 1px solid var(--gray-800);
    transition: all 0.3s ease;
    background-color: var(--white);
}

.course-bg {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.5s ease;
}

/* Imagenes para cada curso */
.bg-unity { background-image: url('images/Unity.png'); }
.bg-shader { background-image: url('images/Shaders.png'); }
.bg-ciber { background-image: url('images/Ciberseguridad.png'); }
.bg-adobe { background-image: url('images/adobe.jpg'); }
.bg-arduino { background-image: url('images/Arduino.png'); }
.bg-pmi { background-image: url('https://images.unsplash.com/photo-1454165804606-c3d57bc86b40?q=80&w=1000&auto=format&fit=crop'); }

.course-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.95), transparent);
    padding: 40px 20px;
    transition: all 0.3s ease;
}

.course-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.course-card:hover .course-bg {
    transform: scale(1.05);
}

.course-card:hover .course-overlay {
    background: linear-gradient(to top, rgba(0,0,0,0.98), transparent);
}

.course-overlay h3 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 8px;
}

.course-overlay p {
    color: var(--gray-300);
    font-size: 1rem;
}

/* --- SECCIÓN CONTACTO --- */
.contact-section {
    padding: 100px 5%;
    background-color: var(--gray-50);
}

.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    max-width: 1400px;
    margin: 0 auto;
}

.contact-info h2 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--black);
    margin-bottom: 20px;
}

.contact-info > p {
    font-size: 1.1rem;
    color: var(--gray-600);
    margin-bottom: 40px;
    line-height: 1.6;
}

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 15px;
    color: var(--gray-700);
    font-size: 1rem;
}

.contact-item i {
    font-size: 1.2rem;
    color: var(--black);
}

.contact-form-wrapper {
    position: relative;
}

.contact-form {
    background: var(--white);
    padding: 40px;
    border: 1px solid var(--gray-200);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.form-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--black);
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--gray-700);
    font-size: 0.9rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid var(--gray-300);
    border-radius: 4px;
    font-size: 1rem;
    font-family: var(--font-body);
    transition: all 0.3s ease;
    background-color: var(--white);
    color: var(--black);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--gray-600);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.form-group.has-error input,
.form-group.has-error select,
.form-group.has-error textarea {
    border-color: #dc2626;
}

.error-message {
    display: block;
    color: #dc2626;
    font-size: 0.85rem;
    margin-top: 5px;
}

.submit-btn {
    width: 100%;
    padding: 16px 32px;
    background-color: var(--black);
    border: none;
    color: var(--white);
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.submit-btn:hover {
    background-color: var(--gray-800);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.submit-btn:disabled {
    background-color: var(--gray-400);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.success-message {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--white);
    padding: 40px;
    text-align: center;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    border: 1px solid var(--gray-200);
}

.success-message.active {
    display: flex;
}

.success-message i {
    font-size: 4rem;
    color: #16a34a;
    margin-bottom: 20px;
}

.success-message h3 {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--black);
    margin-bottom: 10px;
}

.success-message p {
    color: var(--gray-600);
    font-size: 1.1rem;
}

.contact-form.hidden {
    display: none;
}

/* --- FOOTER --- */
footer {
    padding: 60px 5%;
    background-color: var(--black);
    border-top: 1px solid var(--gray-800);
    text-align: center;
}

.footer-logo {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 900;
    color: var(--white);
    margin-bottom: 20px;
}

footer p {
    margin-top: 15px;
    color: var(--gray-500);
}

footer p:last-child {
    font-size: 0.875rem;
    color: var(--gray-600);
}

/* --- MENU HAMBURGUESA --- */
.hamburger-menu {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    width: 30px;
    height: 24px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 5px;
    z-index: 101;
}

.hamburger-menu span {
    width: 100%;
    height: 3px;
    background-color: var(--black);
    border-radius: 3px;
    transition: all 0.3s ease;
}

.hamburger-menu.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.hamburger-menu.active span:nth-child(2) {
    opacity: 0;
}

.hamburger-menu.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

.nav-links.active ~ .hamburger-menu span {
    background-color: var(--gray-600);
}

/* --- ANIMACIONES --- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive */
@media (max-width: 1200px) {
    .hero h1 { font-size: 3.5rem; }
    .hero h1 span { font-size: 1.2rem; }
    .hero p { font-size: 1.1rem; }
}

@media (max-width: 768px) {
    .hamburger-menu {
        display: flex;
    }

    .hero h1 { font-size: 2.5rem; }
    .hero h1 span { font-size: 1rem; }
    .hero p { font-size: 0.95rem; }
    .split-section { flex-direction: column; height: auto; }
    .split-image { height: 250px; }
    .features-grid { grid-template-columns: 1fr 1fr; }
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 20px;
        gap: 15px;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }
    .nav-links.active { display: flex; }
    .contact-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    .contact-section {
        padding: 60px 5%;
    }
}

@media (max-width: 480px) {
    .hero h1 { font-size: 2rem; }
    .hero h1 span { font-size: 0.875rem; }
    .hero p { font-size: 0.85rem; }
    .features-grid { grid-template-columns: 1fr; }
    .section-title { font-size: 2rem; }
    .contact-info h2 { font-size: 2rem; }
    .contact-form { padding: 30px; }
    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 12px 15px;
    }
}
