:root {
    --background-color: #F0EFEA;
    --text-color: #282C2F;
    --accent-color: #015289; 
    --gray-color: #9A9393;
    --dark-gray-color: rgba(0, 0, 0, 0.1);
    --title-font: 'Playfair Display', serif;
    --body-font: 'Inter', sans-serif;
    --fs-h1: clamp(2.8rem, 10vw, 5.5rem);
    --fs-h2: clamp(2rem, 6vw, 3.5rem);
    --fs-body: clamp(1rem, 1.2vw, 1.1rem);
    --padding-section: clamp(4rem, 12vh, 8rem);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--body-font);
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* Estilos Globales */
.section {
    padding: var(--padding-section) 8%;
    max-width: 1200px;
    margin: 0 auto;
}

.italic {
    font-style: italic;
    font-family: var(--title-font);
    font-weight: 400;
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center; 
    align-items: center; 
    text-align: center;     
    padding: 0 8%;
}

/* Contenedor del Menú */

.main-nav {
    position: absolute;
    top: 2.5rem; 
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center; 
    z-index: 10;
}

.nav-links {
    display: flex;
    gap: 3rem;
    list-style: none;
    padding: 0;
    margin: 0;
}

.link-menu {
    text-decoration: none;
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    font-weight: 400;
    letter-spacing: 1.5px;
    color: var(--text-color);
    opacity: 0.6;
    transition: all 0.3s ease;
    position: relative;
}

/* Efecto Hover */
.link-menu:hover,
.link-menu.active {
    opacity: 1;
}

.link-menu::after {
    content: '';
    position: absolute;
    width: 0;
    height: 1px;
    bottom: -5px;
    left: 0;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
}

.link-menu:hover::after,
.link-menu.active::after {
    width: 100%;
}

.nav-logo-mobile, .menu-toggle {
    display: none;
}

.main-title {
    font-family: var(--title-font);
    font-size: var(--fs-h1);
    line-height: 1;
    margin-bottom: 1.5rem;
}

.subtitle {
    font-size: var(--fs-body);
    max-width: 600px;
    color: var(--gray-color);
    margin-top: 1.5rem;
    line-height: 1.8;
}

.highlighted {
    color: var(--text-color);
    font-weight: 600;
    border-bottom: 2px solid var(--accent-color);
}

/* About Grid */
.double-section {
    display: flex;
    flex-wrap: nowrap; 
    height: 100vh;
    overflow: hidden;
}

/* Columna derecha */
.col-sky {
    flex: 1;
    min-width: 50%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10% 5%;
    height: 100vh;
    background-image: url('../assets/clouds.jpeg'); 
    background-size: cover;
    background-position: center;
    animation: slowClouds 60s linear infinite;
    background-blend-mode: multiply;
    background-color: rgba(230, 235, 245, 0.85); 
    color: #1a1a1a; 
    z-index: 1;
    overflow: hidden;
}

.static-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    max-width: 500px;
    z-index: 2;
}

.about-text {
    font-size: var(--fs-body);
    line-height: 1.8;
    color: #28272A;
}

.creative-underline {
    position: relative;
    display: inline-block;
    font-weight: 600;
    z-index: 5;
}

.creative-underline::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 2px; 
    width: 100%;
    height: 45%; 
    background-color: var(--accent-color);
    opacity: 0.35;
    z-index: -1;
    transform: rotate(-0.5deg);
}

.about-text strong {
    display: block;
    margin-top: 1.5rem;
    font-size: 1.1rem;
    color: var(--text-color);
}

@keyframes slowClouds{
    0% { background-position: 0% center; }
    50% { background-position: 100% center; }
    100% { background-position: 0% center; }
}

/* Columna izquierda*/
.col-background {
    flex: 1;
    min-width: 50%;
    height: 100vh;
    overflow-y: auto;
    padding: 6rem 8%;
    box-sizing: border-box;
    -webkit-overflow-scrolling: touch;
}

.col-background::-webkit-scrollbar {
    width: 4px; 
}

.col-background::-webkit-scrollbar-thumb {
    background: var(--accent-color); 
    border-radius: 10px;
}

.col-background::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.02);
}

.inside-scroll{
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.info-div {
    margin-bottom: 0;
}

.info-div h3 {
    font-family: var(--title-font);
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--accent-color);
}

.item-title {
    font-weight: 600;
    margin-top: 0.5rem;
    color: var(--text-color);
}

.item-desc {
    font-size: 0.95rem;
    color: var(--gray-color);
    margin-top: 0.3rem;
}

.sub-skills {
    margin-top: 1.2rem;
}

.sub-skills h4 {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-color);
    margin-bottom: 0.3rem;
}

.sub-skills p {
    font-size: 0.95rem;
    color: var(--gray-color);
}

/* Proyectos */
.projects-list{
    list-style: none;
    margin-top: 3rem;
}

.projects-list li {
    border-bottom: 1px solid #e0e0e0;
}

.project-link-wrapper {
    text-decoration: none;
    display: block;
    padding: 2rem 0;
    color: var(--text-color);
    transition: all 0.4s ease;
}

.projects-list .project-btn {
    font-size: clamp(1.2rem, 3vw, 2rem);
    display: block;
    transition: all 0.4s ease;
}

.project-card {
    margin-top: 0.5rem;
}

.project-card h3 {
    font-family: var(--title-font);
    font-size: 1.4rem;
    color: var(--text-color);
    margin-bottom: 0.3rem;
    transition: color 0.4s ease;
}

.project-card p {
    font-size: 0.95rem;
    color: var(--gray-color);
}

.number {
    font-family: var(--title-font);
    font-style: italic;
    font-size: 1rem;
    margin-right: 1rem;
    color: var(--accent-color);
}

.projects-list .project-btn:hover {
    padding-left: 20px;
    color: var(--accent-color);
}

.project-link-wrapper:hover {
    padding-left: 20px; /* Desplazamiento elegante de todo el bloque */
}

.project-link-wrapper:hover .project-btn,
.project-link-wrapper:hover .project-card h3 {
    color: var(--accent-color); /* Se pinta tu color de énfasis tanto el título como el botón */
}

.parallax-section {
    background-image: url('../assets/corals.JPG');
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
    min-height: 100vh;
    display: flex;
    align-items: center; 
    justify-content: center;
    padding: 100px 5%;
}

.projects-box {
    background-color: var(--background-color);
    padding: clamp(2rem, 5vw, 4rem);
    width: 100%;
    max-width: 900px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    border-radius: 4px;
}

.section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 4rem 8%;
}

.section .subtitle {
    max-width: 650px;
    margin-top: 1.5rem;
    margin-bottom: 2.5rem;
    line-height: 1.8;
}

.contact-button{
    display: inline-block;
    align-self: center;
    margin-top: 2rem;
    padding: 1rem 2rem;
    background-color: var(--text-color);
    color: white;
    text-decoration: none;
    border-radius: 5px; 
    transition: transform 0.3s ease;
}

.contact-button:hover {
    transform: scale(1.05);
    background-color: var(--accent-color);
}

.thanks {
    padding: 20px;
    text-align: center;
    max-width: 600px;
}

.thanks p {
    margin-bottom: 1.5rem;
}

.thanks p:last-child {
    margin-bottom: 0;
    font-size: 0.9rem;
    opacity: 0.7;
    margin-top: 2.5rem;
}

.thanks-text {
    font-size: 1.5rem;
    color: var(--text-color);
    margin-bottom: 0.5rem;
}

#word-changer {
    color: var(--accent-color);
    border-right: 2px solid var(--accent-color);
    padding-right: 5px;
    animation: blink 0.7s infinite;
}

@keyframes blink {
    0% { border-color: var(--accent-color); }
    50% { border-color: transparent; }
    100% { border-color: var(--accent-color); }
}

.portfolio-closure {
    height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    background-color: var(--background-color);
}

.internal-thanks-section {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem 8% 0 8%;
}

.footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 8%;
    background-color: #282C2F;
    width: 100%;
}

.footer-left, .footer-right {
    flex: 1;
    display: flex;
    align-items: center;
}

.footer-right {
    justify-content: flex-end; 
}

.footer-social {
    display: flex;
    gap: 2.5rem;
    justify-content: center;
}

.social-icon {
    color: var(--background-color);
    font-size: 1.2rem;
    opacity: 0.6;
    transition: all 0.3s ease;
    text-decoration: none;
}

.social-icon:hover {
    opacity: 1;
    transform: translateY(-3px);
    color: #FFFFFF;
}

.up-scroll-button {
    color: var(--background-color);
    font-size: 1rem;
    text-decoration: none;
    opacity: 0.5;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(240, 239, 234, 0.3);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.up-scroll-button:hover {
    opacity: 1;
    border-color: #FFFFFF;
    transform: translateY(-5px);
}

.logo-footer {
    display: block;
    max-height: 80px;
    width: auto;
    max-width: 100%;
    object-fit: contain;           
    opacity: 0.8;
    transition: opacity 0.3s ease;
    filter: brightness(0) invert(1);
}

.logo-footer:hover {
    opacity: 1;
}

/* ==========================================================================
   SECCIÓN DISPOSITIVOS MÓVILES (RESPONSIVE)
   ========================================================================== */
@media (max-width: 768px) {

    .main-nav {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 60px;
        background-color: rgba(240, 239, 234, 0.95);
        backdrop-filter: blur(5px);
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 0 6%;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
        z-index: 100;
    }

    .nav-logo-mobile {
        display: block;
    }

    .nav-logo-mobile a {
    text-decoration: none;
    display: inline-block;
    line-height: 0; 
    }

    .mobile-top-logo {
        height: 80px;
        width: auto;
    }

    .menu-toggle {
        display: block;
        background: none;
        border: none;
        color: var(--text-color);
        font-size: 1.5rem;
        cursor: pointer;
        z-index: 110;
        transition: transform 0.3s ease;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        background-color: var(--background-color);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 3rem;
        box-shadow: -10px 0 30px rgba(0,0,0,0.05);
        transition: right 0.4s cubic-bezier(0.1, 1, 0.1, 1);
        z-index: 105;
    }

    .nav-links.open {
        right: 0;
    }

    .link-menu {
        font-size: 1.2rem;
    }

    .double-section {
        display: grid; 
        grid-template-columns: 1fr;
        height: auto;
        overflow: visible;
        background-color: var(--background-color);
    }

    .col-sky {
        display: flex;
        width: 100%;
        min-height: 100vh;
        height: auto;
        padding: 4rem 6%;
        order: 1;
    }

    .col-background {
        width: 100%;
        height: auto;
        padding: 4rem 4% 8rem 4%;
        overflow-y: visible;
        order: 2;
    }

    .inside-scroll {
        display: flex;
        flex-direction: column;
        gap: 3rem;
    }

    .info-div {
        position: sticky;
        top: 80px;
        
        background-color: #FFFFFF;
        padding: 2.5rem 6%;
        border-radius: 12px;
        box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.03), 0 15px 35px rgba(0, 0, 0, 0.05);
        
        min-height: 60vh;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
    }

    .inside-scroll .info-div:nth-child(1) { top: 80px; z-index: 1; }
    .inside-scroll .info-div:nth-child(2) { top: 100px; z-index: 2; }
    .inside-scroll .info-div:nth-child(3) { top: 120px; z-index: 3; }

    .info-div h3 {
        text-align: center;
        font-size: 1.6rem;
        margin-bottom: 1.5rem;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
        padding-bottom: 0.5rem;
    }
    
    .logo-footer {
        max-height: 60px;
        width: 60px;
        filter: brightness(0) invert(1);
    }
    
    .footer {
        flex-direction: column;
        gap: 1.5rem;
        padding: 2rem 5%;
        text-align: center;
    }
    
    .footer-right {
        justify-content: center;
    }
}