:root {
    /* border radius */
    --radius-xs: 2px;
    --radius-s: 4px;
    --radius-m: 8px;
    --radius-l: 16px;
    --radius-xl: 20px;
    --radius-xxxxl: 60px;
    --radius-round: 50%;

    /* font-size */
    --font-size-s: 12px;
    --font-size-regular: 14px;
    --font-size-m: 16px;
    --font-size-xm: 18px;
    --font-size-l: 20px;
    --font-size-xl: 24px;
    --font-size-xxl: 28px;
    --font-size-xxxl: 32px;

    /* font-weight */
    --font-weight-regular: 400;
    --font-weight-medium: 500;
    --font-weight-semi-bold: 600;
    --font-weight-bold: 700;

    /* colors */

    --surface-2: #242424;
    --error: #ff8b83;

    --on-surface: rgba(255, 255, 255, 1);
    --on-surface-400: rgba(255, 255, 255, 0.8);
    --on-surface-350: rgba(255, 255, 255, 0.7);
    --on-surface-300: rgba(255, 255, 255, 0.6);
    --on-surface-200: rgba(255, 255, 255, 0.4);
    --on-surface-112: rgba(255, 255, 255, 0.25);
    --on-surface-100: rgba(255, 255, 255, 0.2);
    --on-surface-50: rgba(255, 255, 255, 0.1);
    --on-surface-40: rgba(255, 255, 255, 0.08);
    --on-surface-10: rgba(255, 255, 255, 0.02);

    --surface: rgba(0, 0, 0, 1);
    --surface-450: rgba(0, 0, 0, 0.9);
    --surface-400: rgba(0, 0, 0, 0.8);
    --surface-300: rgba(0, 0, 0, 0.6);
    --surface-200: rgba(0, 0, 0, 0.4);
    --surface-100: rgba(0, 0, 0, 0.2);
    --surface-50: rgba(0, 0, 0, 0.1);
    --surface-20: rgba(0, 0, 0, 0.04);
    --surface-10: rgba(0, 0, 0, 0.02);
    --surface-0: rgba(0, 0, 0, 0);

    /* Dimens in pixel */
    --dimen-xxs: 2px;
    --dimen-xs: 4px;
    --dimen-sr: 6px;
    --dimen-s: 8px;
    --dimen-m: 12px;
    --dimen-l: 16px;
    --dimen-xl: 20px;
    --dimen-xxl: 24px;
    --dimen-xxlr: 28px;
    --dimen-xxxl: 32px;
    --dimen-xxxlr: 36px;

    /* durations */
    --duration-300: 300ms;
    --font-main: "Inter", Arial, sans-serif;
}

html,
body {
    height: 100%;
    margin: 0;
    padding: 0;
    font-family: var(--font-main);
    background: radial-gradient(
            circle at 50% 40%,
            var(--color-bg-accent) 0%,
            var(--color-bg) 100%
    );
    min-height: 100vh;
}

#bg-video {
    position: fixed;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    z-index: -1;
    object-fit: cover;
    opacity: 0.7;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
}

input {
    padding: var(--dimen-xl) var(--dimen-xxl);
    width: calc(100% - 2 * var(--dimen-xxl));
    background: var(--surface-2);
    border: 1px solid transparent;
    border-radius: var(--radius-xxxxl);
    color: var(--on-surface);
    font-size: var(--font-size-l);
    font-family: var(--font-main);
    outline: none;
    transition: all var(--duration-300) ease;
}

input.error {
    border-color: var(--error);
}

input:-internal-autofill-selected {
    background: var(--surface-2) !important;
}

input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
    background: var(--surface-2) !important;
}

::placeholder {
    color: var(--on-surface-300);
    font-size: var(--font-size-l);
    font-weight: var(--font-weight-regular);
    font-family: var(--font-main);
}

:-ms-input-placeholder {
    color: var(--on-surface-300);
    font-size: var(--font-size-regular);
    font-weight: var(--font-weight-regular);
    font-family: var(--font-main);
}

::-ms-input-placeholder {
    color: var(--on-surface-300);
    font-size: var(--font-size-regular);
    font-weight: var(--font-weight-regular);
    font-family: var(--font-main);
}

button {
    width: 100%;
    padding: var(--dimen-xl) var(--dimen-xxxl);
    background: var(--on-surface);
    border: none;
    border-radius: var(--radius-xxxxl);
    color: var(--surface);
    font-style: var(--font-main);
    font-size: var(--font-size-m);
    font-weight: var(--font-weight-bold);
    cursor: pointer;
    transition: all var(--duration-300) ease;
    font-family: var(--font-main);
    text-align: center;
}

button:hover {
    background: var(--on-surface);
    box-shadow: 0px 8px 24px 9px var(--on-surface-112);
}

button:disabled {
    color: var(--surface);
    background: var(--on-surface-200);
    cursor: not-allowed;
}

.secondary-button {
    width: 100%;
    padding: var(--dimen-l) var(--dimen-xxxl);
    background: transparent;
    border: 1px solid var(--on-surface);
    border-radius: var(--radius-xxxxl);
    color: var(--on-surface);
    font-size: var(--font-size-regular);
    font-weight: var(--font-weight-semi-bold);
    cursor: pointer;
    transition: all var(--duration-300) ease;
    font-family: var(--font-main);
}

.secondary-button:hover {
    color: var(--surface);
}

.tertiary-button {
    background: transparent;
    border: none;
    color: var(--on-surface-300);
    font-size: var(--font-size-m);
    font-weight: var(--font-weight-medium);
    cursor: pointer;
    transition: all var(--duration-300) ease;
    padding: var(--dimen-s) var(--dimen-m);
    width: auto;
}

.tertiary-button:hover:not(:disabled) {
    color: var(--on-surface);
    background: none;
    box-shadow: none;
}

.tertiary-button:disabled {
    opacity: 0.6;
    color: var(--on-surface-300);
    cursor: not-allowed;
    background: none;
    box-shadow: none;
}

.link-button {
    background: none;
    border: none;
    border-bottom: 1px dashed var(--on-surface-200);
    color: var(--on-surface);
    cursor: pointer;
    font-size: var(--font-size-regular);
    text-decoration: none;
    padding: var(--dimen-s);
    margin: 0;
    width: auto;
    border-radius: 0;
}

.link-button:disabled {
    opacity: 0.6;
    color: var(--on-surface-300);
    cursor: not-allowed;
    background: none;
    box-shadow: none;
}

.link-button:hover {
    color: var(--on-surface-400);
    background: none;
    box-shadow: none;
}

h1 {
    margin: 0 !important;
    font-size: var(--font-size-xxl);
    font-weight: var(--font-weight-semi-bold);
    text-align: center;
}

p {
    margin: 0 !important;
    font-size: var(--font-size-m);
    font-weight: var(--font-weight-regular);
    text-align: center;
    color: var(--on-surface-300);
}

.mb-l {
    margin-bottom: var(--dimen-l) !important;
}

input.error {
    border-color: var(--error);
}

.error-message {
    margin-top: calc(var(--dimen-m) * -1);
    color: var(--error);
    font-size: var(--font-size-s);
    margin-left: var(--dimen-l);
    animation: fadeIn var(--duration-300) ease-in-out;
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.form-field {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: var(--dimen-m);
}

.flex-form {
    flex: 1;
}

.form-top {
    display: flex;
    flex-direction: column;
    gap: var(--dimen-l);
}

.form-bottom {
    display: flex;
    flex-direction: column;
    gap: var(--dimen-l);
    margin-top: auto;
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.text-caption {
    opacity: 0.6;
}

.text-sm {
    font-size: var(--font-size-m);
}

.mt-m {
    margin-top: var(--dimen-m);
}

.mt-l {
    margin-top: var(--dimen-l);
}

.mt-xl {
    margin-top: var(--dimen-xl);
}