/**** HEADER TITLE ****/
* {
    box-sizing: border-box;
}

body {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    margin: 0;
    min-height: 100vh;
    font-family: 'DM Sans', sans-serif;
    background-color: #c7d5d8;
}

header h1 {
    margin: 0;
    padding: 10px;
    text-align: center;
    background-color: #0b283c;

    a {
        text-decoration: none;
        color: #f3f4f3;
    }
}

/**** FORM ERRORS ****/
.form-errors {
    border: 5px solid #3c5d7c;
    border-radius: 10px;
    background-color: #f3f4f3;
    margin: 20px;
    padding: 10px;

    ul {
        color: #cf352e;
        margin-bottom: 0;
    }
    h3 {
        font-weight: bold;
        margin-top: 0;
        border-bottom: 2px solid #3c5d7c;
    }
}

/**** FORM LAYOUT ****/
.form-details {
    display: grid;
    grid-template-columns: repeat(2, 1fr); 
    gap: 20px;
    min-height: 100vh;
    max-width: 1200px;
    margin: 0 auto;
    align-items: start;
    padding: 20px;
}

/**** FORM CONTAINER ****/
#form-container {
    margin: 20px;
    padding: 20px;
    border: 5px solid #0b283c;
    background-color: #f3f4f399;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    min-height: 300px;
    display: flex;
    flex-direction: column;

    h1 {
        margin-top: 0;
        text-align: left;
        border-bottom: 5px solid #3c5d7c;
    }
}

/**** SENDER DETAILS ****/
.image-display {
    width: 100%;
    height: 240px;
    margin-bottom: 4px;

    img {
        display: block;
        width: 100%;
        height: 100%;
        max-height: 100%;
        max-width: 100%;
        object-fit: contain;
        border: 1px solid gray;
    }
}

.image-upload {
    display: flex;
    gap: 4px;
    margin-bottom: 16px;
    label {
        display: none;
    }
}

.sender-info {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;

    label {
        align-self: end;
    }

    input {
        width: 100%;
        min-width: 0;
    }
}

/**** RECIPIENT DETAILS ****/
.recipient-info,
.recipient-contact {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5px 15px;
    margin-bottom: 15px;

    input {
        width: 100%;
        min-width: 0;
    }
}

.message-input {
    display: flex;
    flex-direction: column;
    margin-bottom: 15px;

    label {
        border-bottom: 2px solid grey;
    }

    textarea {
        margin-top: 10px;
        width: 100%;
        height: 90px;
        resize: none;
    }
}

.notify-options {
    padding: 10px;
    margin: 0;
    margin-bottom: 10px;

    input {
        margin: 5px;
        vertical-align: middle;
    }
}

/**** PAYMENT DETAILS ****/
.payment-details {
    grid-column: 1 / -1;
    justify-self: center;
    width: min(100%, 450px);
    margin-top: 5px;

    h1 {
        margin-bottom: 15px;
    }
}

.card-details {
    display: grid;
    grid-template-columns: 105px 1fr;
    gap: 15px;
    margin-bottom: 15px;

    div {
        display: flex;
        flex-direction: row;
        gap: 4px;
    }
}

.card-details > div,
.payment-fields > div {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.payment-confirmation {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 5px 15px;
    margin-bottom: 15px;

    input {
        width: 100%;
        min-width: 0;
    }
}

.terms-confirmation {
    display: flex;
    align-items: center;
    justify-content: start;
    gap: 20px;
    margin-top: 10px;
    margin-bottom: 10px;
    font-weight: bold;

    label {
        font-size: 15px;
    }
}

.send-button {
    display: flex;
    justify-content: center;

    button {
        width: 50%;
        padding: 10px;
        background-color: #0b283c;
        border: 2px solid #0b283c;
        border-radius: 10px;
        font-size: 20px;
        color:#f3f4f3;
        cursor: pointer;
    }

    button:hover {
        background-color: #074a6b;
        border-color: #074a6b;
    }
}

/**** FOOTER ****/
footer {
    display: flex;
    flex-direction: row;
    justify-content: center;
    text-align: center;
    background-color: #0b283c;
    color: #c7d5d8;

    p {
        margin: 10px;
        padding: 10px
    }
}