:root {
    --bg-color: white;
    --text-color: #1f1f1f;
    --header-bg-color: #f1f1f1;
    --link-color: #3498db;
    --link-hover-color: #2980b9;
    --button-bg-color: #2980b9;
    --button-hover-bg-color: #3498db;
    --progress-bg-color: #f1f1f1;
    --progress-fill-color: #2980b9;
}

[data-theme='light'] {
    --bg-color: linear-gradient(to right, #61d0f1, #1c92e0);
    --text-color: #1f1f1f;
    --header-bg-color: #f1f1f1;
    --link-color: #3498db;
    --link-hover-color: #2980b9;
    --button-bg-color: #2980b9;
    --button-hover-bg-color: #3498db;
    --progress-bg-color: #f1f1f1;
    --progress-fill-color: #2980b9;
}

[data-theme='dark'] {
    --bg-color: linear-gradient(to right, #434343, #000000);
    --text-color: #ffffff;
    --header-bg-color: #3e3e3e;
    --link-color: #3498db;
    --link-hover-color: #2980b9;
    --button-bg-color: #3498db;
    --button-hover-bg-color: #2980b9;
    --progress-bg-color: #ffffff;
    --progress-fill-color: #3498db;

    /* Cambiar el color del texto en about */
    .about-content p {
        color: #bdc3c7;
    }

    /* Cambiar el color del texto en los proyectos */
    .subtitle {
        color: #bdc3c7;
    }
}

html, body {
    height: 100%;
    margin: 0;
    font-family: 'Roboto', sans-serif;
}

body {
    display: flex;
    flex-direction: column;
}

.wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex: 1;
}

/* Header */
header {
    background-color: #f8f9fa;
    padding: 20px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

header h1 {
    margin: 0;
    color: #343a40;
    font-size: 1.5em;
}

.theme-toggle {
    cursor: pointer;
    display: flex;
    align-items: center;
}

.theme-toggle img {
    width: 24px;
    height: 24px;
    transition: transform 0.3s;
}

nav {
    display: flex;
    align-items: center;
    gap: 20px;
}

nav a {
    color: #007bff;
    text-decoration: none;
    transition: color 0.3s;
    font-size: 1em;
}

nav a:hover {
    color: #0056b3;
}

/* Projects Section */
.projects {
    padding: 100px 20px 50px;
    text-align: center;
    background-color: #f1f1f1;
}

.projects h2 {
    color: #343a40;
    margin-bottom: 10px;
    font-size: 2.5em;
}

.projects .subtitle {
    color: #6c757d;
    margin-bottom: 40px;
    font-size: 1.2em;
}

.project-cards {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
}

.project-card {
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    overflow: hidden;
    max-width: 300px;
    margin: 10px;
}

.project-card img {
    width: 100%;
    height: auto;
    transition: transform 0.3s;
}

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

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

.project-info {
    padding: 20px;
    text-align: left;
}

.project-info h3 {
    color: #007bff;
    margin-top: 15px;
    font-size: 1.5em;
}

.project-info p {
    color: #6c757d;
    margin: 15px 0;
}

.project-gallery {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

.project-gallery img {
    width: 48%;
    border-radius: 5px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    background-color: #007bff;
    color: #fff;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s, color 0.3s;
}

.btn:hover {
    background-color: #0056b3;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: #fff;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 700px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    border-radius: 10px;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close:hover,
.close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}


/* WhatsApp Button */
.whatsapp-float {
    position: fixed;
    width: 60px;
    height: 60px;
    bottom: 40px;
    right: 40px;
    background-color: #25d366;
    border-radius: 50%;
    text-align: center;
    box-shadow: 2px 2px 3px #999;
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
}

.whatsapp-float img {
    width: 50px;
    height: 50px;
}

/* Footer */
.footer {
    background-color: #333;
    color: #fff;
    padding: 20px 0;
    width: 100%;
    text-align: center;
}

.footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.footer-left p {
    margin: 0;
}

.footer-right a {
    margin: 0 10px;
    display: inline-block;
}

.footer-right img {
    width: 24px;
    height: 24px;
}

@media (max-width: 768px) {
    .main h2 {
        font-size: 2.5em;
    }

    .main p {
        font-size: 1em;
    }

    .project-card, .skill {
        width: 45%;
    }

    .about-content {
        flex-direction: column;
    }

    .about-content img {
        margin-bottom: 20px;
    }

    nav {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    nav.active {
        display: flex;
    }
}

@media (max-width: 480px) {
    .main h2 {
        font-size: 2em;
    }

    .main p {
        font-size: 0.9em;
    }

    .project-card, .skill {
        width: 100%;
    }

    header {
        flex-direction: column;
        align-items: flex-start;
        padding: 10px 20px;
    }

    header h1 {
        font-size: 1.2em;
        margin-bottom: 10px;
    }

    .right-header {
        flex-direction: column;
        align-items: flex-start;
    }
}