@font-face {
    font-family: mountains;
    src: url(../fonts/beyond_the_mountains/beyond_the_mountains.woff2);
}

/*@import url('https://fonts.cdnfonts.com/css/beyond-the-mountains');*/

body {
    font-family: Dosis;
    margin: 0;
    padding: 0;
    color: #333;
}

nav {
    background-color: #ad312f;
    padding: 1em;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    /*font-family: 'Beyond The Mountains', sans-serif;*/
    font-family: mountains;
    color: white;
    font-size: 1.5em;
    text-decoration: none;
    position: relative;
    padding-right:0.5em;
}

.logo img {
    height: 1.5em;
    width: auto;
    margin: 0;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    padding-left: .33em;
}

.menu-icon {
    display: none;
    font-size: 2em;
    cursor: pointer;
    color: white;
}

nav ul {
    list-style: none;
    display: flex;
    justify-content: space-around;
    padding: 0;
    margin: 0;
}

nav ul li {
    margin: 0 1em;
}

nav ul li a {
    color: white;
    text-decoration: none;
}

header {
    text-align: center;
    font-family: mountains;
    padding: 20em;
    background: url('../images/wengen-snow.jpg') no-repeat center center;
    background-size: cover;
    color: white;
    text-shadow: .75px .75px 2.5px #ad312f;
}

header h1 {
    font-family: mountains;
    font-size: 3.5em;
    display: block;
    width: 100%;
    height: 100%;
    text-align: center;
}

header h2 {
    width: 100%;
    padding: 0.25em;
    margin: 0;
    text-align: center;
}

section {
    padding: 1em;
    text-align: center;
}

section h3 {
    text-align: center;
}

.team-grid {
    justify-content: center;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1em;
    padding: 2em;
}

.team-member {
    text-align: center;
    border: 1px solid #ccc;
    padding: 1em;
    border-radius: 8px;
    background-color: #f9f9f9;
}

.team-member h3 {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5em;
}

.team-member h3 img {
    width: auto;
    height: 0.5em;
    border-radius: 5%;
}

.team-member img {
    width: 80%;
    height: auto;
    border-radius: 2%;
}

footer {
    background-color: #f1f1f1;
    text-align: center;
    padding: 1em;
    margin-top: 5em;
}

.carousel {
    position: relative;
    max-width: 80%;
    margin: auto;
    box-shadow: 2px 2px 2px 2px Gainsboro;
    padding: 0;
}

.carousel-container {
    position: relative;
    overflow: hidden;
    width: 100%;
    height: 36em; /* Ensure a fixed height for the carousel */
}

.carousel-inner {
    position: relative;
    width: auto;
    height: 100%;
}

.carousel-item {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
    top: 0;
    left: 0;
}

.carousel-item.active {
    opacity: 1;
}

.carousel img {
    width: 100%;
    height: 100%; /* Ensure the image covers the entire item */
    object-fit: cover; /* Maintain aspect ratio and cover the entire item */
    display: inline-block;
    margin: 0 auto;
    position: relative;
    top: 50%;
    transform: translateY(-50%);
    object-fit: cover;
}

/* Animation for menu */
@keyframes menuSlideIn {
    from {
        max-height: 0;
    }
    to {
        max-height: 200px; /* or some appropriate value */
    }
}

@keyframes menuSlideOut {
    from {
        max-height: 200px; /* or some appropriate value */
    }
    to {
        max-height: 0;
    }
}

.menu-slide-in {
    overflow: hidden;
    animation: menuSlideIn 0.75s forwards;
}

.menu-slide-out {
    overflow: hidden;
    animation: menuSlideOut 0.75s forwards;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .menu-icon {
        display: block;
    }

    .nav-links {
        display: none;
        flex-direction: column;
        width: 100%;
        background-color: #ad312f;
    }

    .nav-links.active {
        display: flex;
    }

    .nav-links.menu-slide-in {
        display: flex;
    }

    .nav-links.menu-slide-out {
        display: none;
    }

    .nav-links li {
        margin: 0;
        text-align: center;
        padding: 1em;
        border-top: 1px solid #fff;
    }

    .carousel-container {
        height: 20em; /* Ensure a fixed height for the carousel */
    }

    .carousel {
        max-width: 90%;
    }

    header {
        padding: 12em 1em; /* Adjust padding for smaller screens */
    }

    header h1 {
        font-size: 2em; /* Adjust font size for smaller screens */
    }

    header h2 {
        font-size: 1.5em; /* Adjust font size for smaller screens */
    }
}

@media (min-width: 769px) {
    .nav-links {
        display: flex !important; /* Ensure nav links are displayed */
        flex-direction: row;
        width: auto;
        background-color: transparent;
    }

    .nav-links.menu-slide-in,
    .nav-links.menu-slide-out {
        display: flex !important; /* Ensure nav links are displayed */
    }
}
