/* VARIABLES */
:root {
    --background: #f3f0e9;
    --surface: #e9e5dc;
    --text: #202020;
    --muted: #77736d;
    --blue: #142b50;
    --red: #8b1e35;
    --border: #d5d0c7;
}

/* CONFIGURACIÓN GENERAL */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    background: var(--background);
    color: var(--text);
    font-family: Arial, Helvetica, sans-serif;
    line-height: 1.6;
}

a {
    color: inherit;
    text-decoration: none;
}

section {
    scroll-margin-top: 90px;
}

/* NAVEGACIÓN */
.header {
    width: 100%;
    min-height: 75px;
    padding: 20px 8%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
}

.logo {
    font-size: 25px;
    font-weight: 800;
    letter-spacing: -2px;
}

.logo span,
h2 span {
    color: var(--red);
}

.header nav {
    display: flex;
    gap: 28px;
}

.header nav a {
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: color 0.2s;
}

.header nav a:hover {
    color: var(--red);
}

/* PRESENTACIÓN */
.hero {
    min-height: 650px;
    padding: 100px 12%;
    display: grid;
    grid-template-columns: 1.3fr 0.7fr;
    align-items: center;
    gap: 60px;
    position: relative;
    overflow: hidden;
}

.hero-content {
    max-width: 650px;
}

.eyebrow {
    color: var(--red);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 3px;
    margin-bottom: 22px;
}

.hero h1 {
    font-size: clamp(65px, 9vw, 115px);
    line-height: 0.95;
    letter-spacing: -7px;
    font-weight: 800;
    margin-bottom: 30px;
}

.hero h1 span {
    color: var(--blue);
}

.hero-description {
    max-width: 450px;
    color: var(--muted);
    font-size: 17px;
    margin-bottom: 35px;
}

.button {
    display: inline-block;
    padding: 14px 25px;
    background: var(--blue);
    color: white;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    transition: background 0.2s;
}

.button:hover {
    background: var(--red);
}

/* FOTOGRAFÍA */
.hero-photo {
    width: 100%;
    max-width: 330px;
    height: 420px;
    justify-self: end;
    overflow: hidden;
    border: 1px solid var(--red);
    background: var(--surface);
}

.hero-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.hero-number {
    position: absolute;
    bottom: 35px;
    right: 8%;
    display: flex;
    align-items: center;
    gap: 15px;
}

.hero-number span {
    color: var(--red);
    font-size: 28px;
    font-weight: 800;
}

.hero-number p {
    color: var(--muted);
    font-size: 10px;
    letter-spacing: 2px;
}

/* SECCIONES GENERALES */
.section {
    padding: 100px 12%;
    border-top: 1px solid var(--border);
}

.section-heading {
    margin-bottom: 55px;
}

.section-heading h2 {
    font-size: clamp(40px, 6vw, 65px);
    letter-spacing: -3px;
    line-height: 1.1;
}

.about-content {
    max-width: 800px;
}

.about-content p {
    color: var(--muted);
    font-size: 18px;
    margin-bottom: 22px;
}

/* FORMACIÓN */
.education {
    background: var(--surface);
}

.timeline {
    max-width: 850px;
    border-left: 2px solid var(--red);
    padding-left: 35px;
    margin-left: 8px;
}

.timeline-item {
    position: relative;
    padding-bottom: 45px;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item::before {
    content: "";
    position: absolute;
    left: -42px;
    top: 5px;
    width: 12px;
    height: 12px;
    background: var(--red);
    border-radius: 50%;
}

.date {
    color: var(--red);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.5px;
    margin-bottom: 10px;
}

.timeline-item h3,
.project h3,
.activity h3 {
    font-size: 22px;
    margin-bottom: 7px;
}

.institution {
    color: var(--blue);
    font-weight: 700;
    margin-bottom: 8px;
}

.timeline-item > p:last-child {
    color: var(--muted);
}

/* PROYECTOS */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
}

.project {
    padding: 35px;
    border: 1px solid var(--border);
    transition: border-color 0.2s, transform 0.2s;
}

.project:hover {
    border-color: var(--red);
    transform: translateY(-5px);
}

.project-number {
    color: var(--red);
    font-size: 30px;
    font-weight: 800;
    margin-bottom: 25px;
}

.project > p:not(.project-number):not(.date) {
    color: var(--muted);
    margin-bottom: 20px;
}

.tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

.tag {
    display: inline-block;
    padding: 5px 10px;
    border: 1px solid var(--border);
    color: var(--blue);
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
}

.project-link {
    display: inline-block;
    color: var(--red);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    margin-top: 10px;
}

.project-link:hover {
    text-decoration: underline;
}

/* HABILIDADES */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 35px;
}

.skill-group h3 {
    color: var(--blue);
    font-size: 17px;
    margin-bottom: 20px;
}

.skill-group ul {
    list-style: none;
}

.skill-group li {
    color: var(--muted);
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
    font-size: 14px;
}

/* ACTIVIDADES */
.activities {
    background: var(--surface);
}

.activity {
    max-width: 700px;
}

.activity > p:last-child {
    color: var(--muted);
}

/* CONTACTO */
.contact {
    background: var(--blue);
    color: white;
}

.contact .section-heading h2 {
    color: white;
}

.contact .eyebrow {
    color: #d68b9b;
}

.contact h2 span {
    color: #d68b9b;
}

.contact-description {
    max-width: 600px;
    color: #d0d7e1;
    margin-bottom: 40px;
}

.contact-links {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 25px;
}

.contact-links a {
    font-size: 18px;
    transition: color 0.2s;
}

.contact-links a:hover {
    color: #d68b9b;
}

.contact-label {
    display: block;
    color: #d68b9b;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 5px;
}

.contact-location {
    font-size: 16px;
}

/* PIE DE PÁGINA */
footer {
    padding: 25px 8%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #101d32;
    color: white;
}

footer p,
footer a {
    font-size: 10px;
    letter-spacing: 1.5px;
}

footer a:hover {
    color: #d68b9b;
}

/* DISEÑO RESPONSIVE */
@media (max-width: 900px) {

    .hero {
        padding: 80px 8%;
        gap: 35px;
    }

    .hero h1 {
        font-size: 75px;
    }

    .section {
        padding: 80px 8%;
    }

    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
    }

}

@media (max-width: 650px) {

    .header {
        padding: 18px 6%;
        flex-direction: column;
        gap: 18px;
    }

    .header nav {
        justify-content: center;
        flex-wrap: wrap;
        gap: 15px;
    }

    .header nav a {
        font-size: 10px;
    }

    .hero {
        min-height: auto;
        padding: 75px 8% 110px;
        grid-template-columns: 1fr;
        gap: 35px;
    }

    .hero h1 {
        font-size: 70px;
        letter-spacing: -5px;
    }

    .hero-photo {
        width: 230px;
        height: 290px;
        justify-self: start;
    }

    .hero-number {
        right: 8%;
        bottom: 25px;
    }

    .section {
        padding: 70px 8%;
    }

    .section-heading {
        margin-bottom: 35px;
    }

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

    .project {
        padding: 25px;
    }

    .timeline {
        padding-left: 25px;
    }

    .timeline-item::before {
        left: -32px;
    }

    .contact-links a {
        font-size: 15px;
        overflow-wrap: anywhere;
    }

    footer {
        padding: 25px 6%;
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

}
