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

:root {
    --primary-color: #2b2d42;
    --text-primary: #d1d5db;
    --text-secondary: #9ca3af;
    --bg-primary: #111827;
    --bg-secondary: #1f2937;
    --border-color: #374151;
    --accent-color: #6b7280;
    --bg-nav: rgba(17, 24, 39, 0.95);
    --icon-fill: #d1d5db;
    --highlight-border: #4b5563;
    --lang-color: #ffffff;
    --cursor-fill-dark: #363B3E;
    --cursor-stroke-dark: #ffffff;
    --cursor-fill-light: #9ca3af;
    --cursor-stroke-light: #1f2937;
}

[data-theme="light"] {
    --primary-color: #4b5e8a;
    --text-primary: #1f2937;
    --text-secondary: #6b7280;
    --bg-primary: #f9fafb;
    --bg-secondary: #e5e7eb;
    --border-color: #d1d5db;
    --accent-color: #9ca3af;
    --bg-nav: rgba(249, 250, 251, 0.95);
    --icon-fill: #1f2937;
    --highlight-border: #6b7280;
    --lang-color: #1f2937;
    --cursor-fill-dark: #9ca3af;
    --cursor-stroke-dark: #1f2937;
    --cursor-fill-light: #6ca3af;
    --cursor-stroke-light: #4b5e8a;
}

body {
    font-family: 'Roboto Mono', monospace;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    overflow-x: hidden;
    transition: all 0.3s ease;
    cursor: url("data:image/svg+xml,%3Csvg width='33' height='33' viewBox='0 0 33 33' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cg filter='url(%23filter0_d_8_111)'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M22.4853 16.2985L10.4853 10.7917L13.3235 23.7917L16.7915 18.6571L22.4853 16.2985Z' fill='%23000000'/%3E%3Cpath d='M10.6943 10.3376L22.6943 15.8445L23.7353 16.322L22.6767 16.7605L17.122 19.0613L13.7382 24.072L13.0839 25.0398L12.8349 23.8982L9.99699 10.8982L9.78313 9.91967L10.6943 10.3376Z' stroke='%23ffffff' stroke-miterlimit='16'/%3E%3C/g%3E%3Cdefs%3E%3Cfilter id='filter0_d_8_111' x='6.0808' y='7.04696' width='19.8215' height='23.2402' filterUnits='userSpaceOnUse' color-interpolation-filters='sRGB'%3E%3CfeFlood flood-opacity='0' result='BackgroundImageFix'/%3E%3CfeColorMatrix in='SourceAlpha' type='matrix' values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0' result='hardAlpha'/%3E%3CfeOffset dy='1'/%3E%3CfeGaussianBlur stdDeviation='1.5'/%3E%3CfeColorMatrix type='matrix' values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.25 0'/%3E%3CfeBlend mode='normal' in2='BackgroundImageFix' result='effect1_dropShadow_8_111'/%3E%3CfeBlend mode='normal' in='SourceGraphic' in2='effect1_dropShadow_8_111' result='shape'/%3E%3C/filter%3E%3C/defs%3E%3C/svg%3E"), auto;
}

[data-theme="light"] body {
    cursor: url("data:image/svg+xml,%3Csvg width='33' height='33' viewBox='0 0 33 33' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cg filter='url(%23filter0_d_8_111)'%3E%3Cpath fill-rule='evenodd' clip-rule='evenodd' d='M22.4853 16.2985L10.4853 10.7917L13.3235 23.7917L16.7915 18.6571L22.4853 16.2985Z' fill='%23000000'/%3E%3Cpath d='M10.6943 10.3376L22.6943 15.8445L23.7353 16.322L22.6767 16.7605L17.122 19.0613L13.7382 24.072L13.0839 25.0398L12.8349 23.8982L9.99699 10.8982L9.78313 9.91967L10.6943 10.3376Z' stroke='%231f2937' stroke-miterlimit='16'/%3E%3C/g%3E%3Cdefs%3E%3Cfilter id='filter0_d_8_111' x='6.0808' y='7.04696' width='19.8215' height='23.2402' filterUnits='userSpaceOnUse' color-interpolation-filters='sRGB'%3E%3CfeFlood flood-opacity='0' result='BackgroundImageFix'/%3E%3CfeColorMatrix in='SourceAlpha' type='matrix' values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0' result='hardAlpha'/%3E%3CfeOffset dy='1'/%3E%3CfeGaussianBlur stdDeviation='1.5'/%3E%3CfeColorMatrix type='matrix' values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.25 0'/%3E%3CfeBlend mode='normal' in2='BackgroundImageFix' result='effect1_dropShadow_8_111'/%3E%3CfeBlend mode='normal' in='SourceGraphic' in2='effect1_dropShadow_8_111' result='shape'/%3E%3C/filter%3E%3C/defs%3E%3C/svg%3E"), auto;
}

/* Ensure consistent cursor for all interactive elements */
body *,
button,
a,
.cta-button,
.theme-toggle,
.lang-toggle,
.social-link,
.submit-btn,
.project-link,
.skill-tag,
.timeline-content,
.project-card {
    cursor: inherit !important;
}

/* Navegación */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--bg-nav);
    backdrop-filter: blur(10px);
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 40px;
    transition: transform 0.3s ease;
}

.logo:hover img {
    transform: scale(1.05);
}

.nav-content {
    display: flex;
    align-items: center;
    gap: 2rem;
    flex-grow: 1;
    justify-content: center;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-primary);
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

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

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

.nav-controls {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.theme-toggle,
.lang-toggle {
    background: none;
    border: none;
    width: 24px;
    height: 24px;
    transition: all 0.3s ease;
}

.theme-toggle img {
    width: 100%;
    height: 100%;
    fill: var(--icon-fill);
}

.lang-toggle {
    color: var(--lang-color);
    font-size: 1rem;
    font-weight: 500;
}

.theme-toggle:hover,
.lang-toggle:hover {
    transform: scale(1.1);
}

/* Contenido principal */
main {
    margin-top: 70px;
}

.section {
    min-height: 100vh;
    padding: 4rem 0;
    display: flex;
    align-items: center;
    position: relative;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    width: 100%;
}

/* Sección Inicio */
.hero {
    text-align: center;
    animation: fadeInUp 1s ease-out;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--text-primary);
    position: relative;
    letter-spacing: 0.05em;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: letter-spacing 0.3s ease;
}

.hero-content h1:hover {
    letter-spacing: 0.1em;
}

.hero-content h1::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 2px;
}

.hero-content .subtitle {
    font-size: 1.5rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-weight: 400;
}

.hero-content .description {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-button {
    display: inline-block;
    background: var(--primary-color);
    color: #ffffff; /* Texto blanco en ambos modos */
    padding: 1rem 2rem;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}

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

/* Sección About */
.about {
    background: var(--bg-secondary);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text h2 {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.about-text p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.skills {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1rem;
    margin-top: 2rem;
}

.skill-tag {
    background: var(--bg-primary);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.skill-tag:hover {
    background: var(--primary-color);
    color: var(--text-primary);
    transform: translateY(-2px);
}

.about-image {
    text-align: center;
}

.profile-image {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border-color);
    box-shadow: 0 0 0 4px var(--bg-primary);
    margin: 0 auto;
}

/* Sección Experience */
.experience h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
}

.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 100%;
    background: var(--border-color);
}

.timeline-item {
    position: relative;
    margin: 2rem 0;
    padding: 0 2rem;
}

.timeline-item:nth-child(odd) {
    text-align: right;
}

.timeline-item:nth-child(even) {
    text-align: left;
}

.timeline-content {
    background: var(--bg-primary);
    padding: 2rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    transition: transform 0.3s ease;
}

.timeline-content:hover {
    transform: translateY(-5px);
}

.timeline-content h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    position: relative;
    -webkit-text-stroke: 1px var(--highlight-border);
    text-shadow: none;
}

.timeline-content .company {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.timeline-dot {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 12px;
    height: 12px;
    background: var(--primary-color);
    border-radius: 50%;
    top: 2rem;
}

/* Sección Projects */
.projects {
    background: var(--bg-secondary);
}

.projects h2 {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 3rem;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.project-card {
    background: var(--bg-primary);
    border-radius: 8px;
    padding: 2rem;
    border: 1px solid var(--border-color);
    transition: transform 0.3s ease;
}

.project-card:hover {
    transform: translateY(-5px);
}

.project-info h3 {
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.project-info p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.tech-tag {
    background: var(--bg-secondary);
    padding: 0.3rem 0.8rem;
    border-radius: 8px;
    font-size: 0.8rem;
    color: var(--text-primary);
}

.project-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.project-link:hover {
    color: var(--accent-color);
}

/* Sección Contact */
.contact {
    text-align: center;
}

.contact h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.contact p {
    color: var(--text-secondary);
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

.contact-form {
    max-width: 600px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 1.5rem;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-primary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    background: var(--bg-secondary);
    color: var(--text-primary);
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

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

.submit-btn {
    background: var(--primary-color);
    color: var(--text-primary);
    padding: 1rem 2rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}

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

.social-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.social-link {
    width: 40px;
    height: 40px;
    background: var(--bg-secondary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}

.social-link svg {
    width: 20px;
    height: 20px;
    fill: var(--icon-fill);
}

.social-link:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
}

.social-link:hover svg {
    fill: var(--text-primary);
}

/* Footer */
footer {
    background: var(--bg-secondary);
    padding: 1rem 0;
    text-align: center;
    border-top: 1px solid var(--border-color);
    margin-top: 2rem;
}

footer p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Animaciones */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeInUp 0.8s ease-out;
}

/* Responsive */
@media (max-width: 768px) {
    .nav-container {
        flex-wrap: wrap;
        justify-content: space-between;
    }

    .nav-content {
        justify-content: center;
        flex-wrap: wrap;
    }

    .nav-links {
        display: none;
    }

    .nav-controls {
        display: flex;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .hero-content h1::after {
        width: 80%;
    }

    .about-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .timeline::before {
        left: 20px;
    }

    .timeline-item {
        text-align: left;
        padding-left: 4rem;
    }

    .timeline-dot {
        left: 20px;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .section {
        padding: 2rem 0;
    }

    .profile-image {
        width: 200px;
        height: 200px;
    }

    footer {
        padding: 1rem;
    }
}