/* -----------------------
CONTACT SPLASH
----------------------- */

#contact-cover {
    background-image: linear-gradient(transparent, black, black);
    position: absolute;
    height: 60%;
    width: 100vw;
    bottom: 0;
    opacity: 50%;
}

#contact-container {
    color: var(--white);
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    bottom: 4em;
    position: absolute;
    height: fit-content;
}

#contact-details, #contact-about {
    position: relative;
    z-index: 10;
}

#contact-details {
    padding-right: 2em;
    border-right: 1px solid var(--dark-grey);
}

#contact-details h2, #contact-details div {
    text-align: right;
}

#contact-about {
    padding-left: 2em;
    border-left: 1px solid var(--dark-grey);
    width: 75%;
}

#mobile-splash-title-container {
    display: none;
}

#mobile-splash-title {
    font-size: 4rem !important;
    margin-top: 40vh;
}



/* -----------------------
CONTACT GENERAL
----------------------- */

#contact {
    padding-bottom: 8em;
    padding-top: 4em;
    row-gap: 8em;
}

fieldset {
    all: unset;
}

#contact-info {
    grid-column: 2 / 4;
}

#project-info {
    grid-column: 5 / 8;
    justify-self: center;
    width: 66%;
}

#file-upload {
    grid-column: 9 / 11;
    display: flex;
    flex-direction: column;
    
}

#file-upload h2 { flex-grow: 10; }

#contact-title {
    margin-top: calc(50vh - 0.5em);
    font-size: 6em;
    text-align: center;
    grid-column: 1 / -1;
    position: relative;
    z-index: 10;
    margin-bottom: 8rem;
}

#contact h1 {
    text-align: left;
    font-size: 2em;
}

#contact h2 {
    font-family: var(--title-font);
    font-size: 2rem;
}

#contact h2 {
    margin-bottom: 1rem;
}

#contact-email, #contact-phone {
    margin-bottom: 1em;
    overflow-wrap: break-word;
    max-width: 100%;
    min-width: 0;
}

#contact-email {
    margin-top: 1em;
}

label {
    display: block;
    color: var(--dark-grey);
    font-style: oblique;
}

#name {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

input[type="text"] {
    border: none;
    background-color: transparent;
    border-bottom: 1px solid var(--nav-trans);
    font-family: var(--body-font);
    font-size: 1em;
    margin-bottom: 1em;
}

#emailaddress, #phonenumber, #streetaddress {
    width: 100%;
}

input[type="text"]:focus {
    outline: none;
    border-color: var(--accent);
}

select {
    font-size: 1em;
    font-family: var(--body-font);
    border: none;
    border-bottom: 1px solid var(--nav-trans);
    background-color: transparent;
    margin-bottom: 1em;
}

textarea {
    border: none;
    background-color: transparent;
    border-bottom: 1px solid var(--nav-trans);
    width: 100%;
    aspect-ratio: 4 / 3;
    resize: none;
    font-size: 1em;
    font-family: var(--body-font);
    padding: 1em;
    margin-left: -1em;
    background-color: var(--light-grey);
}

textarea:focus {
    outline: none;
    border-color: var(--accent);
}

.g-recaptcha {
    grid-column: 5 / 8;
    justify-self: center;
    text-align: center;
    align-self: center;
    width: 66%;
}

#contact-mobile-border {
    display: none;
}

#draganddrop {
    border: 1px solid var(--black);
    width: 100%;
    aspect-ratio: 4 / 3;
    border-radius: 1em;
    padding: 1em;
    margin-left: -1em;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

#dropbg {
    position: absolute;
    opacity: 0;
    transition: opacity 1s;
    background-image: linear-gradient(to bottom right, rgba(102, 51, 153, 0.744), rgba(130, 59, 139, 0.79));
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    border-radius: 1em;
}

#upload-controls-wrapper {
    display: flex;
    flex-direction: row;
    align-self: center;
}

#draganddrop input, #draganddrop label {
    position: relative;
    z-index: 10;
}

#draganddrop[data-dragover="true"] #dropbg {
    opacity: 100;
}

::file-selector-button {
    margin-right: 1em;
    background-color: var(--white);
    color: var(--black);
    font-size: .75rem;
}

input[type="file"] {
    font-family: var(--body-font);
    margin: 1em;
    color: transparent;
    font-size: 0;
}

#dropgallery {
    position: absolute;
    top: 1em;
    max-width: calc(100% - 2em);
    max-height: calc(100% - 2em);
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 2px;
    overflow-y: scroll;
}

#dropgallery:has(> :last-child:nth-child(1)) {
    grid-template-columns: repeat(1, minmax(0, 1fr));
}

#dropgallery:has(> :last-child:nth-child(2)) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
#dropgallery:has(> :last-child:nth-child(3)) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

#dropgallery img {
    max-width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    display: block;
}

#remove-uploads {
    position: relative;
    font-size: .75em;
    line-height: 1em;
    background-image: radial-gradient(circle at center, var(--red) 50%, var(--white) 50%);
    transition-duration: 0s;
    background-color: var(--white);
}

#remove-uploads:hover {
    color: white;
    transition-duration: .1s;
}

#upload-info {
    font-size: .75em;
    background-color: var(--white);
    padding: 1rem;
    margin-left: .3em;
    font-style: italic;
    display: inline-block;
    position: relative;
    border-radius: 2rem;
}




/* -----------------------
CONTACT MOBILE
----------------------- */
@media (max-width: 480px) {
    #splash {
        height: fit-content !important;
        min-height: 100vh;
        position: relative;
    }

    #contact {
        margin-top: -4em;
    }
    #contact-container {
        grid-column: 2 / -2;
        display: grid;
        grid-template-columns: auto;
        row-gap: 2em;
        width: 100%;
    }

    #contact-title {
        margin: 50vw 0 0 0 !important;
        padding-top: 4rem;
        padding-bottom: 4rem;
        margin-top: 50vh;
        margin-bottom: 50vh;
    }

    #mobile-splash-title-container {
        display: block;
    }
    #splash-title-container {
        display: none;
    }

    fieldset {
        grid-column: 2 / 11 !important;
        width: 100% !important;
    }

    #contact-container fieldset:first-of-type {
        border-left: 1px solid var(--dark-grey);
        border-right: 0;
        padding: 0 0 0 2em;
    }

    #contact-container fieldset:first-of-type h2, #contact-container fieldset:first-of-type div {
        text-align: left !important;
    }

    #contact {
        row-gap: 4em;
    }

    #contact-info {
        margin-top: 8rem;
    }

    #contact-details, #contact-about {
        width: 100%;
        padding-right: 2rem;
        box-sizing: border-box;
    }

    #contact-details {
        padding-left: 2em;
        border-left: 1px solid var(--dark-grey);
        padding-right: 0;
        max-width: 100%;
        min-width: 0;

        border-right: 0;
        margin-bottom: 0;
    }

    #contact-details h2, #contact-details div { text-align: left !important; }

    #contact-mobile-border {
        grid-column: 1 / -1;
        height: 1px;
        background-color: var(--dark-grey);
        display: block;
    }

    .g-recaptcha {
        grid-column: 2 / 11;
        width: 100%;
    }
}