html,
body {
    min-height: 100%;
    margin: 0;
    padding: 0;
}

body {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

* { box-sizing: border-box; }

nav {
    display: flex;
    align-items: center;
    position: fixed;
    width: 100%;
    justify-content: space-between;
    flex-direction: row;
    min-height: 88px;
    padding: 0 2.5em;
    background-color: rgba(10, 10, 10, .15);
    backdrop-filter: blur(6px);
    z-index: 1000;
}

.nav-logo {
    margin-right: 1em;
    transition: all 0.3s ease;
}

.nav-logo:hover {
    font-weight: 700;
    letter-spacing: 0.5px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2.5em;
    margin: 0 0 0 auto;
    padding: 0;
    list-style: none;
}

.nav-links li {
    position: relative;
    margin: 0;
    text-transform: capitalize;
    font-family: "Roboto", Helvetica, sans-serif;
    color: var(--color-white);
    font-weight: 600;
    letter-spacing: 0.1px;
}

.nav-links li small {
    text-transform: lowercase;
}

.nav-links a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: #8f2525;
    background: rgba(143, 37, 37, 0.15);
}

.nav-dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    font-family: "Iceland", sans-serif;
    font-size: 1.2em;
    color: #8f2525;
    background: rgba(245, 245, 245, 0.75);
    border-radius: 4px;
    border: 0;
    cursor: pointer;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.02em;
    height: 42px;
}

.nav-dropdown-toggle:hover {
    color: #9e1515;
    background: rgba(245, 245, 245, 0.95);
    border-radius: 4px;
}

.nav-dropdown-toggle .nav-dropdown-icon {
    display: inline-block;
    transition: transform 0.2s ease;
}

.nav-dropdown-menu {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    z-index: 100;
    min-width: 272px;
    margin: 0;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 0;
    background: rgba(20, 20, 20, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 4px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}

.nav-dropdown-menu li {
    width: 100%;
    color: var(--color-white);
    list-style: none;
}

.nav-dropdown-menu a {
    display: block;
    padding: 10px 12px;
    color: var(--color-white);
    white-space: nowrap;
    font-weight: 500;
    letter-spacing: 0.05em;
}

.nav-dropdown-menu a:hover,
.nav-dropdown-menu a:focus {
    color: rgb(143, 37, 37);
    background: rgba(245, 245, 245, 0.95);
    font-weight: 550;
    border-radius: 4px;
}

.nav-dropdown.open .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-dropdown.open .nav-dropdown-toggle .nav-dropdown-icon {
    transform: rotate(180deg);
}


/* RESPONSIVE NAV: SMALLER DEVS */
.nav {
    position: fixed;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

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

.mobile-nav {
    display: none;
    position: relative;
}

.menu-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 42px;
    height: 42px;
    padding: 8px;
    border: 0;
    background: transparent;
    cursor: pointer;
    border: 1px solid var(--color-white);
    border-radius: 8px;
    transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}

.menu-toggle:focus,
.menu-toggle:hover {
    border-color: var(--color-lightgrey);
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--color-white);
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.mobile-menu {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    display: none;
    flex-direction: column;
    min-width: 210px;
    padding: 0.75em;
    gap: 0.1em;
    background: var(--color-lightgrey);
    /* background: rgba(204, 204, 204, 0.9); */
    backdrop-filter: blur(10px);
    border-radius: 8px;
    z-index: 1000;
    transition:
        background 0.25s ease,
        color 0.25s ease,
        border-color 0.25s ease,
        transform 0.25s ease;
}

.mobile-menu a {
    text-decoration: none;
    font-family: 'Iceland';
    color: var(--color-negro);
    font-size: 1.3em;
    font-weight: 500;
    letter-spacing: 0.04em;
    width: 300px;
    padding: 0.35em 0.5em;
}

.mobile-nav.is-open .mobile-menu {
    display: flex;
}

.mobile-nav.is-open .menu-toggle span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.mobile-nav.is-open .menu-toggle span:nth-child(2) {
    opacity: 0;
}

.mobile-nav.is-open .menu-toggle span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}
/* **************************************************** */


/* =========================================================
   CTA
   ========================================================= */

.primary-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 0.5em 1.75em;
    background: var(--color-red);
    color: var(--color-white);
    border: 1px solid var(--color-black);
    border-radius: 4px;
    text-decoration: none;
    text-transform: uppercase;
    font-family: "Iceland", sans-serif;
    font-size: 1.2em;
    font-weight: 600;
    letter-spacing: 0.04em;
    height: 42px;
    transition:
        background 0.25s ease,
        color 0.25s ease,
        border-color 0.25s ease,
        transform 0.25s ease;
    box-shadow: 2px 2px 2px rgba(var(--color-black-rgb), 0.5);
}

.primary-cta:hover {
    background: var(--color-red-bright);
    color: var(--color-white) !important;
    border-color: rgba(255, 255, 255, 0.65);
    transform: translateY(-2px);
    box-shadow: none;
}

.mobile-menu .primary-cta {
    margin-top: .6em;
    font-weight: 600;
    color: var(--color-lightgrey) !important;
}

.mobile-menu .primary-cta:hover {
    background: var(--color-red-dark);
    border-color: var(--color-black);
}


main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: calc(100vh - 88px);
}

footer {
    display: flex;
    justify-content: center;
    flex-direction: column;
    background-color: rgba(10, 10, 10, 0.45);
    padding: 1.25em;
    text-align: center;
    min-height: 50px;
    margin-top: auto;
    backdrop-filter: blur(6px);
}

footer p {
    margin: 0;
    font-size: 0.9em;
    font-family: "Cambay", sans-serif;
    color: var(--color-white);
    font-weight: 600;
}

.footer-developer {
    font-size: 0.8em;
    font-family: "Roboto", Helvetica, sans-serif;
    margin-top: 1em;
    color: rgb(204, 203, 203);
}

footer a {
    color: inherit;
    text-decoration: none;
    font-weight: 600;
}


/* ** MESSAGES *************************************/

.messages {
    position: absolute;
    top: 20px;
    left: 50%;
    z-index: 1000;
    width: min(90%, 460px);
    transform: translateX(-50%);
}

.message {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 14px 16px;
    margin-bottom: 10px;
    color: var(--color-black);
    font-family: "Roboto", Helvetica, sans-serif;
    font-size: 0.9rem;
    background: var(--color-white);
    border-left: 4px solid var(--color-darkgrey);
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.18);
}

.message-success {
    border-left-color: #3c7a57;
}

.message-error {
    border-left-color: #a33;
}

.message-warning {
    border-left-color: #b8860b;
}

.message-info {
    border-left-color: #4f6870;
}

.message-close {
    padding: 0;
    color: inherit;
    font-size: 1.25rem;
    line-height: 1;
    background: transparent;
    border: 0;
    cursor: pointer;
}


@media (max-width: 762px) {
    .nav-links {
        display: none;
    }

    .mobile-nav {
        display: block;
    }

    .mobile-nav .mobile-menu a:hover {
        background-color: rgba(var(--color-red-rgb), 0.5);
        max-width: 100%;
        border-radius: 4px;
        /* padding: 0.25em 0.5em; */
    }

}


@media (max-width: 566.98px) {
    nav {
        padding: 0 1em;
    }

    .nav-dropdown-toggle {
        padding: 0 0.5em;
        font-size: 1.2rem;
        height: 36px;
    }
}


@media (max-width: 388px) {
    .mobile-nav .mobile-menu a {
        width: 280px;
    }

    .mobile-nav.is-open .mobile-menu {
        width: 100% !important;
        min-width: 280px;
        padding: .75em 1em;
    }

    .mobile-nav .primary-cta {
        max-width: 100%;
    }

}

