form fieldset {
    border: 0 none;
    margin: 0;
    padding: 0;
}

form legend {
    padding: 8px 0;
    color: #333;
}

form legend.required::after {
    content: ' *';
    color: red;
}

input[type=text],
input[type=email],
input[type=tel],
input[type=date],
input[type=password],
input[type=number],
textarea,
select {
    font-family: sans-serif;
    font-size: 14px;

    margin: 0;
    padding: 4px 8px;
    line-height: 24px;

    border: 1px solid #999;
    border-radius: 0;
    background-color: #FFF;
    color: #000;

    /*vertical-align: top;*/

    box-sizing: border-box;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

/* INFO: Hide the HTML5 number input’s spin box */
/* https://stackoverflow.com/questions/3790935/can-i-hide-the-html5-number-input-s-spin-box */
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
    /* display: none; <- Crashes Chrome on hover */
    -webkit-appearance: none;
    margin: 0; /* <-- Apparently some margin are still there even though it's hidden */
}

input[type=number] { -moz-appearance:textfield; /* Firefox */ }

textarea {
    min-height: 100px;
    resize: vertical;
    /*padding-top: 5px;*/
}

/* remove dropdown arrow on IE from select */
select::-ms-expand { display: none; }

select {
/*    width: 100%;*/

    box-sizing: border-box;

    background-image: url(../svg/form/down.svg);
    background-size: 28px 28px;
    background-repeat: no-repeat;
    background-position: right center;
    padding: 4px 30px 4px 6px;
    max-width: 100%;
}

input[type=text]:disabled,
input[type=email]:disabled,
input[type=password]:disabled,
textarea:disabled,
select:disabled {
    color: #333;
    background-color: #EEE;
}

.w100 input[type=text],
.w100 input[type=email],
.w100 input[type=tel],
.w100 input[type=date],
.w100 input[type=number],
.w100 input[type=password],
.w100 textarea,
.w100 select,
.w100 button,
.w100 {
    width: 100%;
    box-sizing: border-box;
}

select option {
    padding: 6px;
}

/* checkbox */
label.checkbox {
    line-height: 16px;
    /*white-space: nowrap;*/
    padding: 5px 20px 5px 30px;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    vertical-align: bottom;
    display: inline-block;
}

label.checkbox input { display: none;}

label.checkbox span {
    display: inline-block;
    width: 16px;
    height: 16px;
    background-color: #FFF;
    border: 1px solid #2457AA;
    border-radius: 3px;
    content: ' ';
    vertical-align: bottom;
    margin-right: 6px;
    margin-left: -30px;
}

label.checkbox:hover span { border-color: #2457AA; }

label.checkbox input:checked + span {
    background-image: url(../svg/form/check.svg);
    background-color: #2457AA;
    background-position: center;
}

@media all and (max-width: 470px) {
    label.checkbox { display: block; }
}
/* checkbox END */


/*custom radio*/
label.radio {
    line-height: 16px;
    padding: 5px 20px 5px 30px;
    vertical-align: middle;
    display: inline-block;
}

label.radio input { display: none;}

label.radio span {
    display: inline-block;
    width: 14px;
    height: 14px;
    background-color: #FFF;
    border: 1px solid #2457AA;
    border-radius: 50%;
    content: ' ';
    vertical-align: middle;
    margin-left: -30px;
    margin-right: 5px;
}

label.radio input:checked + span {
    background-image: url(../svg/form/circle.svg);
    background-position: center;
}
/* custom radio END */


/* formerror */
.mgErrorField {
    border: 1px solid #ff0000 !important;
    /*background-color: #fffee4 !important;*/
}

.mgErrorTooltip {
    font-family: sans-serif;
    font-size: 14px;
    line-height: 20px;

    position: absolute;
    max-width: 520px;
    padding: 7px 20px 7px 10px;
    text-align: left;
    border-radius: 4px;
    color: #fff;
    background-color: #c40000;
    box-shadow: 1px 1px 3px 0 rgba(0,0,0,0.35);
    margin-top: 2px;
    z-index: 1;
}

.mgErrorTooltip:after {
    height: 0;
    width: 0;
    bottom: 100%;
    left: 25px;
    border: solid transparent;
    content: " ";
    position: absolute;
    border-color: rgba(196, 0, 0, 0);
    border-bottom-color: #c40000;
    border-width: 7px;
    margin-left: -7px;
}

label.checkbox .mgErrorTooltip,
label.radio .mgErrorTooltip {
    margin: 5px 0 0 -30px;
}
/* formerror */

@media only screen and (-webkit-min-device-pixel-ratio: 1.5),
only screen and (-o-min-device-pixel-ratio: 3/2),
only screen and (min--moz-device-pixel-ratio: 1.5),
only screen and (min-device-pixel-ratio: 1.5) {
    input,
    textarea,
    select {
        font-size: 18px !important;
        line-height: 28px !important;
        padding: 5px 10px !important;
        height: 38px !important;
    }

    button,
    button.cancel {
        font-size: 18px !important;
        line-height: 28px !important;
        padding: 5px 20px !important;
        height: 38px !important;
    }
}

section.form > form {
    background-color: #242528;
    padding: 40px 10px 20px 10px;
    margin: 80px auto;
}

section.form h2 { margin: 0 0 20px 0; }

form.dark input[type=text],
form.dark input[type=date],
form.dark input[type=number],
form.dark input[type=email],
form.dark input[type=tel],
form.dark select,
form.dark textarea {
    border-radius: 6px;
    border: none;
    background-color: #121214;
    color: #CCC;
    font-size: 15px;
    padding: 6px 10px;
}

form.dark label.checkbox span {
    background-color: #121214;
    border: 1px solid #B9AB52;
}

form.dark label.checkbox:hover span { border-color: #B9AB52; }

form.dark label.checkbox input:checked + span {
    background-image: url(../svg/form/check_gold.svg);
    background-color: #B9AB52;
}

form.dark a { color: #FFF; }

footer form.dark input[type=email] { background-color: #242528; }

form.dark button[type=submit] {
    display: inline-block;
    position: relative;
    z-index: 0;
    background: transparent;
    border: 2px solid #B9AB52;
    border-radius: 5px;
    color: #fff;
    font-family: 'Oswald', sans-serif;
    font-weight: 400;
    font-size: 16px;
    text-transform: uppercase;
    text-decoration: none;
    letter-spacing: 1px;
    padding: 4px 30px;
    cursor: pointer;
}

form.dark button[type=submit]::before {
    content: "";
    position: absolute;
    background-color: #B9AB52;
    border-radius: 5px;
    left: 0;
    top: 0;
    height: 100%;
    width: 0;
    transition: 350ms ease-in-out, 500ms clip-path ease-in-out;
    color: #fff;
    z-index: -1;
}

form.dark button[type=submit]:hover::before { width: 100%; }

form.dark legend { color: #CCC; }


form.dark.disabled { position: relative; }

/*form.dark .mgLoader {  }*/

form.dark .mgLoader {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, .5);

    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;

    opacity: 0;
    transition: 700ms ease-in-out opacity;
}

.gray {
    background-color: #242528;
    padding: 40px;
}

#Recipient p,
.gray p { margin-top: 0; }

.gray p { margin-block: 6px; }

.edit-order {
    background-image: url(../svg/arrow-left.svg);
    background-size: 15px;
    background-position: 15px center;
    background-repeat: no-repeat;
    padding: 8px 20px 8px 40px;
}

@media(max-width: 981px) {
    .gray { padding: 20px 10px; }
}

@media(min-width: 981px) {
/*    #Recipient,#Invoice { margin-block: 40px; }*/

    .gray { padding: 40px; }
}