/* =====================================================
   VARIABLES
===================================================== */

:root {
    --green: #16804b;
    --green-dark: #0f5d37;
    --green-soft: #eaf4ee;

    --red: #c92b35;
    --red-dark: #9f2029;
    --red-soft: #f8e9e9;

    --cream: #faf8f2;
    --white: #ffffff;

    --black: #171717;
    --gray: #666666;
    --light-gray: #e4e1d8;

    --max-width: 1200px;
}


/* =====================================================
   RESET
===================================================== */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Montserrat", sans-serif;
    background: var(--cream);
    color: var(--black);
    line-height: 1.6;
}

img {
    width: 100%;
    display: block;
    object-fit: cover;
}

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

button,
input,
select,
textarea {
    font: inherit;
}


/* =====================================================
   GENERAL
===================================================== */

.container {
    width: min(90%, var(--max-width));
    margin: 0 auto;
}

.section {
    padding: 110px 0;
    position: relative;
}

.section-label {
    color: var(--green);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    margin-bottom: 18px;
}

.section h2 {
    font-family: "Cormorant Garamond", serif;
    font-size: clamp(2.5rem, 5vw, 4.3rem);
    font-weight: 500;
    line-height: 1;
}

.button {
    display: inline-block;
    border: none;
    cursor: pointer;
    padding: 15px 28px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    transition: 0.25s ease;
}

.button-primary {
    background: var(--red);
    color: white;
}

.button-primary:hover {
    background: var(--red-dark);
    transform: translateY(-2px);
}


/* =====================================================
   TRICOLOR SEPARATORS
===================================================== */

.intro::before,
.courses::before,
.about::before,
.gallery::before,
.contact::before {
    content: "";

    position: absolute;

    top: 0;
    left: 0;

    width: 100%;
    height: 10px;

    background: linear-gradient(
        90deg,
        var(--green) 0%,
        var(--green) 33.33%,
        #ffffff 33.33%,
        #ffffff 66.66%,
        var(--red) 66.66%,
        var(--red) 100%
    );
}


/* =====================================================
   HEADER
===================================================== */

.header {
    position: fixed;
    top: 0;
    left: 0;

    width: 100%;

    z-index: 1000;

    background: rgba(250, 248, 242, 0.96);

    backdrop-filter: blur(12px);

    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.nav-container {
    min-height: 78px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 30px;
}

.logo {
    font-family: "Cormorant Garamond", serif;
    font-size: 1.4rem;
    font-weight: 600;
    white-space: nowrap;
}

.logo-green {
    color: var(--green);
}

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

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

.nav a {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.08em;

    transition: color 0.2s ease;
}

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

.language-switcher {
    display: flex;
    align-items: center;
    gap: 5px;

    font-size: 0.72rem;
    font-weight: 600;
}

.language-button {
    background: none;
    border: none;

    cursor: pointer;

    color: #999;

    font-weight: 600;
}

.language-button.active {
    color: var(--green);
}

.menu-button {
    display: none;

    border: none;
    background: none;

    font-size: 1.5rem;

    cursor: pointer;
}


/* =====================================================
   HERO
===================================================== */

.hero {
    min-height: 100vh;

    position: relative;

    display: flex;
    align-items: center;

    background:
        linear-gradient(
            90deg,
            rgba(0, 0, 0, 0.68),
            rgba(0, 0, 0, 0.25)
        ),
        url("../imagenes/hero.jpg") center / cover;

    color: white;
}

.hero::after {
    content: "";

    position: absolute;

    bottom: 0;
    left: 0;

    width: 100%;
    height: 12px;

    background: linear-gradient(
        90deg,
        var(--green) 0%,
        var(--green) 33.33%,
        #ffffff 33.33%,
        #ffffff 66.66%,
        var(--red) 66.66%,
        var(--red) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 2;

    padding-top: 80px;

    max-width: 850px;
}

.hero .eyebrow {
    color: #ffffff;

    font-size: 0.72rem;

    font-weight: 600;

    letter-spacing: 0.2em;

    margin-bottom: 22px;
}

.hero h1 {
    font-family: "Cormorant Garamond", serif;

    font-size: clamp(4rem, 9vw, 8rem);

    line-height: 0.82;

    font-weight: 500;
}

.hero h1 em {
    color: #ffffff;
    font-weight: 400;
}

.hero-text {
    max-width: 500px;

    margin: 35px 0;

    font-size: 1rem;

    color: rgba(255, 255, 255, 0.88);
}


/* =====================================================
   INTRO
===================================================== */

.intro {
    background: var(--white);
}

.intro-grid {
    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 100px;

    align-items: start;
}

.intro-grid > div:first-child {
    position: relative;
}

.intro-grid > div:first-child::after {
    content: "";

    display: block;

    width: 70px;
    height: 4px;

    margin-top: 30px;

    background: linear-gradient(
        90deg,
        var(--green) 0 33%,
        white 33% 66%,
        var(--red) 66% 100%
    );
}

.intro p:not(.section-label) {
    color: var(--gray);

    margin-bottom: 20px;
}


/* =====================================================
   SECTION HEADING
===================================================== */

.section-heading {
    display: flex;

    justify-content: space-between;
    align-items: end;

    gap: 40px;

    margin-bottom: 60px;
}

.section-heading > p {
    max-width: 350px;

    color: var(--gray);
}


/* =====================================================
   COURSES
===================================================== */

.courses {
    background: var(--cream);
}

.courses::before {
    height: 14px;
}

.courses-grid {
    display: grid;

    grid-template-columns: repeat(3, 1fr);

    gap: 25px;
}

.course-card {
    background: var(--white);

    border: 1px solid var(--light-gray);

    position: relative;

    overflow: hidden;

    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease;
}

.course-card::before {
    content: "";

    position: absolute;

    top: 0;
    left: 0;

    width: 100%;
    height: 4px;

    background: var(--green);

    z-index: 2;
}

.course-card:nth-child(2)::before {
    background: #ffffff;
    border-bottom: 1px solid var(--light-gray);
}

.course-card:nth-child(3)::before {
    background: var(--red);
}

.course-card:hover {
    transform: translateY(-7px);

    box-shadow:
        0 20px 45px rgba(0, 0, 0, 0.08);
}

.course-image {
    height: 270px;

    position: relative;

    overflow: hidden;
}

.course-image img {
    height: 100%;

    transition: transform 0.5s ease;
}

.course-card:hover .course-image img {
    transform: scale(1.04);
}

.course-number {
    position: absolute;

    top: 18px;
    right: 18px;

    background: white;

    color: var(--red);

    padding: 7px 11px;

    font-size: 0.7rem;

    font-weight: 600;
}

.course-content {
    padding: 30px;
}

.course-level {
    color: var(--green);

    font-size: 0.65rem;

    font-weight: 600;

    letter-spacing: 0.15em;

    margin-bottom: 12px;
}

.course-content h3 {
    font-family: "Cormorant Garamond", serif;

    font-size: 2rem;

    font-weight: 600;

    line-height: 1;

    margin-bottom: 18px;
}

.course-content > p {
    color: var(--gray);

    font-size: 0.9rem;

    margin-bottom: 25px;
}

.course-button {
    border: none;

    border-bottom: 1px solid var(--red);

    background: none;

    padding-bottom: 5px;

    color: var(--red);

    cursor: pointer;

    font-size: 0.7rem;

    font-weight: 600;

    letter-spacing: 0.1em;
}


/* =====================================================
   ABOUT
===================================================== */

.about {
    background: var(--white);
}

.about::before {
    height: 14px;
}

.about-grid {
    display: grid;

    grid-template-columns: 0.9fr 1.1fr;

    gap: 100px;

    align-items: center;
}

.about-image {
    height: 650px;

    position: relative;
}

.about-image::before {
    content: "";

    position: absolute;

    top: 15px;
    left: 15px;

    width: 100%;
    height: 100%;

    border: 3px solid var(--green);

    z-index: 0;
}

.about-image::after {
    content: "";

    position: absolute;

    bottom: -10px;
    right: -10px;

    width: 80px;
    height: 80px;

    background: var(--red);

    z-index: 0;
}

.about-image img {
    height: 100%;

    position: relative;

    z-index: 1;
}

.about-content h2 {
    margin-bottom: 35px;
}

.about-content > p:not(.section-label) {
    color: var(--gray);

    max-width: 550px;

    margin-bottom: 18px;
}


/* =====================================================
   GALLERY
===================================================== */

.gallery {
    background: var(--cream);
}

.gallery::before {
    height: 14px;
}

.gallery-grid {
    display: grid;

    grid-template-columns: repeat(3, 1fr);

    grid-auto-rows: 250px;

    gap: 15px;
}

.gallery-item {
    overflow: hidden;

    position: relative;
}

.gallery-item::after {
    content: "";

    position: absolute;

    bottom: 0;
    left: 0;

    width: 100%;
    height: 4px;

    background: var(--green);
}

.gallery-item:nth-child(2)::after,
.gallery-item:nth-child(5)::after {
    background: var(--red);
}

.gallery-item img {
    height: 100%;

    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.04);
}

.gallery-large {
    grid-column: span 2;
}


/* =====================================================
   CONTACT
===================================================== */

.contact {
    background: var(--white);
}

.contact::before {
    height: 14px;
}

.contact-grid {
    display: grid;

    grid-template-columns: 0.9fr 1.1fr;

    gap: 100px;
}

.contact-intro h2 {
    margin-bottom: 30px;
}

.contact-intro > p:not(.section-label) {
    max-width: 450px;

    color: var(--gray);
}

.contact-links {
    margin-top: 45px;

    max-width: 450px;
}

.contact-link {
    display: flex;

    justify-content: space-between;

    padding: 18px 0;

    border-top: 1px solid var(--light-gray);

    font-size: 0.8rem;

    font-weight: 600;

    transition: color 0.2s ease;
}

.contact-link:last-child {
    border-bottom: 1px solid var(--light-gray);
}

.contact-link:hover {
    color: var(--red);
}

.whatsapp-link span:first-child {
    color: var(--green);
}

.instagram-link span:first-child {
    color: var(--red);
}


/* =====================================================
   FORM
===================================================== */

.contact-form {
    display: flex;

    flex-direction: column;

    gap: 25px;

    position: relative;
}

.form-group {
    display: flex;

    flex-direction: column;

    gap: 8px;
}

.form-group label {
    font-size: 0.7rem;

    font-weight: 600;

    letter-spacing: 0.08em;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;

    border: none;

    border-bottom: 1px solid #ccc;

    background: transparent;

    padding: 12px 0;

    outline: none;

    color: var(--black);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--green);
}

.form-group textarea {
    resize: vertical;
}

.contact-form .button {
    align-self: flex-start;
}

#form-message {
    font-size: 0.85rem;

    color: var(--green);
}


/* =====================================================
   FOOTER
===================================================== */

.footer {
    background: var(--black);

    color: white;

    padding: 35px 0;

    border-top: 8px solid transparent;

    border-image:
        linear-gradient(
            90deg,
            var(--green) 0 33.33%,
            white 33.33% 66.66%,
            var(--red) 66.66% 100%
        ) 1;
}

.footer-content {
    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 30px;
}

.footer p {
    color: #999;

    font-size: 0.7rem;
}


/* =====================================================
   MOBILE
===================================================== */

@media (max-width: 900px) {

    .nav {
        position: absolute;

        top: 78px;
        left: 0;

        width: 100%;

        display: none;

        flex-direction: column;

        background: var(--cream);

        padding: 30px;

        border-bottom: 1px solid var(--light-gray);
    }

    .nav.active {
        display: flex;
    }

    .menu-button {
        display: block;
    }

    .language-switcher {
        margin-left: auto;
    }

    .intro-grid,
    .about-grid,
    .contact-grid {
        grid-template-columns: 1fr;

        gap: 50px;
    }

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

    .about-image {
        height: 500px;
    }

    .section-heading {
        align-items: start;

        flex-direction: column;
    }
}


@media (max-width: 600px) {

    .section {
        padding: 75px 0;
    }

    .hero h1 {
        font-size: clamp(3.5rem, 17vw, 5rem);
    }

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

    .course-image {
        height: 300px;
    }

    .gallery-grid {
        grid-template-columns: 1fr 1fr;

        grid-auto-rows: 180px;
    }

    .gallery-large {
        grid-column: span 2;
    }

    .footer-content {
        flex-direction: column;

        align-items: flex-start;
    }

    .nav-container {
        gap: 15px;
    }

    .logo {
        font-size: 1.15rem;
    }
}
