html {
    overflow: auto;
    overscroll-behavior: none;
}

body {
    height: 100%;
    margin: 0;
    display: flex;
    justify-content: center;
    flex-direction: column;
    background-color: rgba(224, 247, 250, 1);
    font-family: Inter;
}

body:not(.loaded) {
    opacity: 0;
}

.loaded {
    transition: opacity 0.5s ease-in;
}

#navbar {
    position: fixed;
    top: 0;
    width: 100%;
    height: 12vh;
    background-color: white;
    display: flex;
    justify-content: space-around;
    z-index: 2;
}

#logo {
    max-width: 300px;
    height: auto;
    align-self: center;
    margin-left: 20px;
    user-select: none;
}

#nav {
    list-style: none;
    text-align: center;
    margin: 0;
    padding: 0;
    align-content: center;
    margin-right: 20px;
    user-select: none;
}

#mobile-nav {
    user-select: none;
    background-color: white;
    overflow: hidden;
    border-top: 1px solid black;
    position: absolute;
    top: 12vh;
    visibility: hidden;
    height: 0;
    width: 100%;
    margin: 0;
    padding: 0;
    transition: all 0.5s ease-out, opacity 0.5s ease-out;
}

#mobile-nav.visible {
    visibility: visible;
    height: 225px;
    max-height: 225px;
}

#mobile-nav li {
    opacity: 0;
    font-size: 20px;
    margin: 0;
    padding: 10px;
    list-style: none;
    transition: opacity 1s ease-out;
    margin-bottom: 1px;
}

#mobile-nav li.visible {
    opacity: 1;
    visibility: visible;
    outline: 1px solid black;
}

#mobile-nav li.visible:last-of-type {
    opacity: 1;
    outline: none;
}

#nav img {
    align-self: center;
}

#nav li {
    display: inline;
    font-size: 20px;
    margin: 0;
    padding: 10px;
}

#nav li:last-of-type {
    background-color: rgb(44, 62, 179);
    border-radius: 10px;
    font-weight: bold;
    color: white;
    transition: all 0.3s ease-out;
}

#nav li:last-of-type:hover {
    cursor: pointer;
    filter: invert(1);
    text-decoration: none;
}

li:hover {
    text-decoration: underline;
    cursor: pointer;
}

#main-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

#main {
    background-image: url("images/nimage.jpg");
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    padding-top: 18vh;
    display: flex;
    flex-direction: column;
    height: auto;
    width: 100%;
    justify-content: center;
    align-content: center;
}

#contact-form {
    background: rgba(255, 255, 255, 1);
    width: 50%;
    flex: 1;
    position: fixed;
    top: 55%;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 50px;
    display: flex;
    box-sizing: border-box;
    flex-direction: column;
    overflow: auto;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease-out;
    z-index: 1;
}

#contact-form #top-info {
    border: none;
    font-size: 36px;
    background: none;
    padding-bottom: 20px;
    align-self: flex-end;
    width: 100%;
    top: 0;
    right: 10px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

#contact-form .close-btn {
    height: 36px;
    width: 36px;
    font-size: 24px;
    text-align: center;
    border: none;
    background: none;
    cursor: pointer;
    position: absolute;
    right: 10px;
    top: 10px;
    transition: color 0.3s ease-in-out;
}

#contact-form .close-btn:hover {
    color: red;
}

#contact-form h3 {
    margin: 10px 0 0 0;
}

.spinner {
    box-sizing: border-box;
    border: 3px solid white;
    border-top: 3px solid rgb(211, 193, 76);
    border-radius: 50%;
    width: 16px;
    height: 16px;
    animation: spin 0.6s linear infinite;
    display: inline-block;
    vertical-align: middle;
    transform-origin: center;
    backface-visibility: hidden;
    transform: translateZ(0);
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.form-row {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

label {
    font-size: 1.2rem;
    width: 120px;
    user-select: none;
    justify-self: center;
}

input,
select,
textarea {
    width: 100%;
    font-size: 1.2rem;
    flex: 1;
    box-sizing: border-box;
    padding: 0.6rem;
}

textarea {
    font-family: inherit;
    resize: none;
}

input::file-selector-button {
    border: none;
    border-radius: 5px;
    background-color: rgb(211, 193, 76);
    padding: 0.3rem;
}

button[type="submit"] {
    width: 100%;
    font-size: 1.2rem;
    flex: 1;
    box-sizing: border-box;
    padding: 0.6rem;
}

button[type="submit"] {
    background-color: rgb(44, 62, 179);
    border: none;
    border-radius: 5px;
    color: white;
    cursor: pointer;
}

#contact-form.visible {
    background-color: white;
    opacity: 1;
    pointer-events: all;
}

@media (max-width: 1110px) {
    #contact-form {
        bottom: 5%;
        width: 90%;
        height: 65vh;
    }

    .form-row {
        flex-direction: column;
        align-items: flex-start;
        margin-bottom: 0.5rem;
    }

    label {
        font-size: 1rem;
        width: 100%;
        text-align: left;
        margin-right: 0;
        margin-bottom: 0.3rem;
    }

    input,
    select,
    textarea {
        width: 100%;
        flex: none;
        font-size: 1rem;
    }

    button[type="submit"] {
        width: 100%;
        flex: none;
        font-size: 1rem;
    }

    input#file {
        padding-left: 0;
    }

    .spinner {
        width: 16px;
        height: 16px;
    }
}

#main div.container {
    width: 90%;
    margin: auto;
    height: 82vh;
    display: flex;
    flex-direction: column;
    align-content: center;
    text-align: center;
    gap: 20px;
}

#main div.text {
    color: white;
    text-shadow: 0px 0px 10px black;
    user-select: none;
}

#main div.text p {
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
    padding: 5px;
}

#main div.services {
    color: black;
    user-select: none;
}

#main div.about {
    margin-top: 0;
    color: black;
    text-align: left;
    user-select: none;
}

#main div.contacts {
    align-self: flex-start;
    width: 100%;
    margin-top: 0;
    color: black;
    text-align: left;
    user-select: none;
}

#main div.contacts p {
    font-size: 24px;
}

#main div.contacts a {
    font-size: 24px;
    text-decoration: none;
    color: black;
}

#image-full {
    align-self: center;
    width: 90%;
    height: 90%;
    padding-bottom: 20px;
    object-fit: cover;
    object-position: 60%;
}

#image-full[alt="contact-us"] {
    object-position: 75%;
}

#main h1 {
    font-size: clamp(4rem, 10vw, 10rem);
    font-weight: 600;
    margin: 30px 0 10px 0;
}

#main h2 {
    font-size: clamp(2rem, 10vw, 3rem);
    font-weight: 600;
    margin: 30px 0 10px 0;
}

#main p {
    margin: 0;
    font-size: clamp(1.5rem, 2vw, 8rem);
    text-wrap: wrap;
}

#main p1 {
    margin: 0;
    font-size: clamp(1rem, 2vw, 1.5rem);
    text-wrap: wrap;
}

.container button {
    width: auto;
    margin-top: 20px;
    margin-bottom: 40px;
    padding: 8px;
    border: none;
    border-radius: 10px;
    color: white;
    background-color: rgba(0, 0, 0, 0.5);
    align-self: center;
    font-size: 32px;
    font-weight: bold;
    transition: all 0.3s ease-out;
    text-shadow: 0px 0px 5px black;
}

.container button:hover {
    cursor: pointer;
    transform: scale(1.05);
    filter: invert(1);
    text-shadow: none;
}

#services {
    padding-top: 10vh;
    padding-bottom: 6vh;
    align-self: center;
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    align-items: center;
    justify-content: center;
}

#services div {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 480px;
    user-select: none;
}

#services h3 {
    text-align: center;
}

#services img {
    height: 250px;
    width: 250px;
    object-fit: cover;
    border-radius: 25px;
}

#footer {
    background-color: rgb(38, 50, 56);
    color: white;
    display: flex;
    flex-direction: column;
}

#footer .bottom-1 {
    display: flex;
    justify-content: space-around;
    width: 80%;
    align-self: center;
    flex-wrap: wrap;
    padding: 10px;
}

.footer-container {
    min-width: 300px;
    box-sizing: border-box;
}

#footer .bottom-2 {
    align-self: center;
}

#footer a {
    color: white;
    text-decoration: none;
}

#footer a:hover {
    color: blue;
    text-decoration: underline;
}
