:root {
    --neutral-color: #fff;
    --neutral-dark-color: #bdbdbd;
    --neutral-secondary-color: #e4e1f0;
    --primary-color: #000;
    --primary-color-hover: #3a3a48;
    --secondary-color: #c5db29;

    --error-primary-color: #950202;
    --error-secondary-color: #ff0000;

    --nav-bg: var(--primary-color);
    --footer-bg: var(--primary-color);
    --nav-fg: var(--neutral-color);
    --copyright-fg: var(--neutral-secondary-color);

    --primary-font-family: "Montserrat", sans-serif;
    --max-container-width: 1540px;

    --btn-primary-color: #c1d62e; /*#c1d62e;*/
    --btn-secondary-color: #f0f5cb;
}

* {
    font-family: var(--primary-font-family);
    box-sizing: border-box;

    /* scrollbar styling for firefox */
    scrollbar-width: 1rem;
    scrollbar-color: var(--btn-primary-color) var(--neutral-color);
}

@supports (-moz-appearance: none) {
    select option {
        -moz-appearance: none !important;
        background: var(--neutral-color) !important;
        border: none !important;
    }
}

/* width */
::-webkit-scrollbar {
    width: 1rem;
}

/* Track */
::-webkit-scrollbar-track {
    background: var(--neutral-color);
}

/* Handle */
::-webkit-scrollbar-thumb {
    background: var(--btn-primary-color);
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
    background: var(--btn-primary-color);
}

:is(.nav-container, .footer-container, footer > *, main) {
    max-width: var(--max-container-width);
    margin-left: auto;
    margin-right: auto;
}
.hidden.hidden {
    display: none;
}

html {
    font-size: 100%;
}

body {
    display: flex;
    position: relative;
    flex-flow: column nowrap;
    justify-content: flex-start;
    margin: 0;
    background-color: var(--neutral-color);
    box-sizing: border-box;
    height: 100%;
    min-height: 100vh;
}

.form-error {
    color: var(--error-primary-color);
    font-weight: bold;
    font-size: 1.125rem;
}

nav {
    width: 100%;
    background-color: var(--nav-bg);
    padding: 1.25rem;
    height: auto;
    box-sizing: border-box;
    flex-grow: 0;
    flex-shrink: 0;
}
.nav-dropdown-container {
    width: var(--max-container-width);
    max-width: 100%;
    display: flex;
    justify-content: flex-end;
    margin: 0 auto;
}

.primary-button {
    background-color: var(--primary-color);
    color: var(--neutral-color);
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: bold;
}
.primary-button:hover {
    background-color: var(--primary-color-hover);
    cursor: pointer;
}

main {
    flex-grow: 1;
    align-self: stretch;
}

main a {
    color: var(--primary-color);
}
main a:is(:hover) {
    color: var(--primary-color);
    cursor: pointer;
}

main.invoice-form {
    display: flex;
    flex-flow: column nowrap;
    justify-content: center;
    align-items: center;
    align-content: center;
    width: 100%;
    height: 100%;
}
main.main-form {
    display: block;
    /* flex-flow: column nowrap; */
    /* justify-content: center; */
    /* align-items: center; */
    /* align-content: center; */
    width: 100%;
    padding-bottom: 80px;
    padding-top: 40px;
}
main.main-form > * {
    max-width: 100%;
    width: calc(var(--max-container-width) / 2);
    margin: 0 auto;
    text-align: center;
    /* padding: 1.25rem; */
}
main.main-form > :is(h1, h2) {
    padding: 0.5rem 0;
}
main.main-form > h2:last-of-type {
    padding-bottom: 1.5rem;
}
main > h1 {
    color: var(--primary-color);
    font-size: 2.5rem;
}

.main-404 {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    flex-flow: column wrap;
}
.main-404 > * {
    display: block;
    width: 100%;
    margin: 0.75rem 0;
}
.main-404 > p {
    font-weight: bold;
}

.form-wrap {
    display: block;
    padding: 1.25rem;
    text-align: left;
    width: 100%;
    max-width: 100%;
}

main form {
    padding: 1.25rem;
}

main form a {
    font-weight: 500;
    color: #0000ff;
}
main form a:is(:hover) {
    font-weight: 500;
    color: #0000aa;
}
.invoice-form > img,
.main-form > img {
    max-width: 100%;
    width: 260px;
    /* padding-bottom: 4.5rem; */
}
.main-form > img {
    display: block;
    margin: 0 auto;
}
.invoice-form.invoice-form :is(input[type="text"]) {
    margin-bottom: 2.5rem;
}
.invoice-form.invoice-form .form-wrap {
    max-width: 600px;
    margin: 0 auto;
}
.invoice-disclaimer {
    font-weight: 500;
    color: var(--primary-color);
    font-size: 1rem;
    padding: 0 1.25rem;
    text-align: center;
}
.invoice-disclaimer:last-of-type {
    margin-bottom: 50px;
}

.form-wrap > div {
    text-align: left;
}
.form-wrap label {
    display: block;
    font-weight: bold;
    color: var(--primary-color);
    margin-left: 0.5rem;
    margin-top: 3rem;
}
.form-wrap h1 {
    margin-left: 0.5rem;
    color: var(--primary-color);
}
.main-form > :is(h1, h2, p) {
    color: var(--primary-color);
}
.invoice-form > :is(h1, h2, p) {
    color: var(--primary-color);
}
.invoice-form > p {
    padding-top: 0.25rem;
}
.form-wrap :is(input[type="text"], textarea, select) {
    font-size: 1rem;
    font-weight: 500;
    width: 100%;
}
.form-wrap :is(input[type="text"], input[type="password"], textarea, select) {
    display: block;
    padding: 0.75rem 0;
    margin: 20px 0;
    width: 100%;
    /* border: solid 2px var(--primary-color); */
    background-color: transparent;
    border-top: none;
    border-left: none;
    border-right: none;
    border-bottom: 1px solid var(--primary-color);
    color: var(--primary-color);
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: var(--primary-color) !important;
    margin-left: 0.5rem;
    margin-top: 0.625rem;
}
.form-wrap :is(input[type="text"], input[type="password"], textarea, select):-webkit-autofill {
    color: var(--primary-color);
}
.form-wrap :is(input[type="text"], input[type="password"], textarea, select):focus {
    outline: none;
}
.form-wrap :is(input[type="text"], input[type="password"], textarea, select)::placeholder {
    color: var(--primary-color);
}
.form-wrap :is(input[type="text"], input[type="password"], textarea, select):-ms-input-placeholder {
    color: var(--primary-color);
}
.form-wrap :is(input[type="text"], input[type="password"], textarea, select)::-ms-input-placeholder {
    color: var(--primary-color);
}
.form-wrap :is(input[type="text"], input[type="password"], textarea, select)::-webkit-input-placeholder {
    color: var(--primary-color);
}
.form-wrap :is(input[type="text"], input[type="password"], textarea, select):-moz-placeholder {
    color: var(--primary-color);
    opacity: 1;
}

.invoice-lookup-submit {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    margin-top: -20px;
}

.form-wrap .submit-btn {
    position: relative;
    text-decoration: none;
    will-change: transform;
    font-size: 1rem;
    -webkit-appearance: none;
    user-select: none;
    overflow: hidden;
    font-weight: bold;
    text-transform: uppercase;
    background-color: var(--btn-primary-color);
    border: 0;
    transition: all 350ms ease 0s;
    -webkit-transition: all 350ms ease 0s;
    padding: 0 1.25rem;
    text-align: center;
}
.form-wrap .submit-btn {
    display: inline-block;
    width: 209px;
    height: 50px;
    line-height: 2.5rem;
    border-radius: 3.75rem;
    padding-left: 2.8rem;
    margin-top: 1.25rem;
}
.form-wrap .submit-btn:before {
    content: "";
    position: absolute;
    top: 0;
    right: -1px;
    width: calc(100% + 2px);
    height: 100%;
    /* background: var(--primary-color); */
    z-index: -1;
    margin-top: 0;
    border-radius: 28px;
    pointer-events: none;
    transition: background 0.3s linear, width 0.3s cubic-bezier(0.23, 1, 0.32, 1), height 0.4s cubic-bezier(0.23, 1, 0.32, 1), margin-top 0.3s cubic-bezier(0.23, 1, 0.32, 1), transform 0.3s cubic-bezier(0.23, 1, 0.32, 1), right 0.4s cubic-bezier(0.23, 1, 0.32, 1), top 0.3s cubic-bezier(0.23, 1, 0.32, 1), border-radius 0.4s cubic-bezier(0.23, 1, 0.32, 1), left 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    will-change: width, height, margin-top, top, right, border-radius;
    line-height: 2.5rem;
    /* color: var(--primary-color); */
}
.form-wrap .submit-btn:hover:before {
    width: 40px;
    height: 40px;
    margin-top: -20px;
    background-color: var(--btn-primary-color);
    border-radius: 50px;
    top: 50%;
    left: auto;
    right: 14px;
}
.form-wrap .submit-btn:hover {
    background: var(--btn-secondary-color);
    border-color: var(--btn-secondary-color);
    color: var(--primary-color);
    outline: 0;
    cursor: pointer;
}

.form-wrap .submit-btn:hover > input[type="submit"] {
    color: var(--btn-primary-color);
}
.form-wrap .submit-btn > input[type="submit"] {
    width: 100% !important;
    margin: 0 !important;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.1rem;
    line-height: 1.75rem;
    text-align: left;
    color: var(--primary-color);
    background: transparent;
    border: 0;
    cursor: pointer;
    padding: 0;
    text-transform: inherit !important;
    -webkit-appearance: button;
    overflow: visible;
    font-family: inherit;
    /* padding-top: 5px; */
    vertical-align: bottom;
    /* margin-top: -1.25rem !important; */
}
.form-wrap .submit-btn > input[type="submit"]:hover {
    color: var(--btn-primary-color);
    background: transparent;
}
.form-wrap .submit-btn > .svg-icon {
    position: absolute;
    right: 20px;
    margin-top: -11px;
    top: 50%;
    line-height: 1.625rem;
    color: var(--primary-color);
}
.form-wrap .submit-btn > .svg-icon > img {
    width: 28px;
    height: 23px;
    max-width: 100%;
    border-style: none;
    color: var(--primary-color);
}

.form-wrap input[type="submit"] {
    background-color: var(--primary-color);
    color: var(--neutral-color);
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: bold;
    font-size: 1rem;
}
.form-wrap input[type="submit"]:hover {
    background-color: var(--primary-color-hover);
    cursor: pointer;
}
.form-wrap .register-recover {
    margin-top: 26px;
    margin-bottom: 36px;
}

.nav-container {
    display: flex;
    flex-flow: row nowrap;
    justify-content: space-between;
    align-items: center;
}
.nav-container img {
    height: 80px;
}
.navmenu {
    display: flex;
    position: relative;
    flex-flow: row wrap;
    color: var(--nav-fg);
    font-size: 1.25rem;
    align-items: center;
    gap: 1.25rem;
}
.navmenu a {
    color: var(--nav-fg);
}
.navmenu a:visited {
    color: var(--nav-fg);
}
.navmenu a:active {
    color: var(--nav-fg);
}
.navmenu a:hover {
    color: var(--nav-fg);
    text-decoration: underline;
}
.nav-dropdown a {
    color: var(--nav-fg);
}
.nav-dropdown a:visited {
    color: var(--nav-fg);
}
.nav-dropdown a:active {
    color: var(--nav-fg);
}
.nav-dropdown a:hover {
    color: var(--nav-fg);
    text-decoration: underline;
}

footer {
    background-color: var(--footer-bg);
    padding: 1.25rem;
    box-sizing: border-box;
    align-self: flex-end;
    justify-self: flex-end;
    width: 100%;
    flex-grow: 0;
    flex-shrink: 0;
}
.footer-container {
    display: flex;
    flex-flow: row nowrap;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 1.25rem;
}
footer img {
    display: block;
    height: 70px;
}
footer p {
    padding-top: 0;
    margin-top: 0.375rem;
    color: var(--neutral-color);
    font-size: 1rem;
    line-height: 1.25rem;
    font-family: var(--primary-font-family);
    font-weight: 500;
}
footer hr {
    color: #ddd;
    background-color: #ddd;
}
footer .copyright {
    font-family: var(--primary-font-family);
    font-size: 0.75rem;
    line-height: 0.875rem;
    margin-bottom: 0;
    color: var(--copyright-fg);
}

invoice-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-flow: row nowrap;
}
invoice-header > * {
    display: block;
}
invoice-header > input {
    flex: 0;
    width: 120px;
    height: 2.5rem;
}
invoice-header > h2 {
    flex: 1;
}

invoice-row {
    cursor: pointer;
}

.profile-wrap {
    padding: 1.25rem 0.25rem;
    cursor: pointer;
}
.nav-dropdown-container {
    --dropdown-width: 140px;
}
.nav-dropdown {
    position: absolute;
    height: auto;
    width: var(--dropdown-width);
    padding: 0 1.5rem 1rem;
    /* top: 82px; */
    /* right: 0; */
    background-color: var(--nav-bg);
    text-align: right;
    font-size: 1.25rem;
}
.nav-dropdown-container-row {
    width: var(--dropdown-width);
}
.nav-dropdown > * {
    display: block;
    padding: 0.35rem 0;
}
.nav-dropdown a {
    text-decoration: none;
    font-weight: 500;
}
.nav-dropdown a:hover {
    text-decoration: underline;
}
.mb-nav-tab {
    display: none;
}

@media only screen and (max-width: 768px) {
    .nav-container img {
        height: 50px;
    }
    .mb-nav-tab {
        display: block;
    }
    .dt-nav-tab {
        display: none;
    }
}
