:root {
    color-scheme: light dark;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body.gradient-background {
    background: linear-gradient(135deg, #a8e9e3 0%, #fefefe 35%, #fefefe 65%, #b1acfd 100%);
    background-size: 100% 100%;
    background-attachment: fixed;
}

@media (prefers-color-scheme: dark) {
    body.gradient-background {
        background:
            linear-gradient(135deg, #4dd0c0 0%, #66d4ca 20%, #7bc7d4 35%, #8fb8dd 50%, #a3a9e5 65%, #b7a0ed 80%, #c997f4 100%);
        background-size: 100% 100%;
        background-attachment: fixed;
        position: relative;
    }

    body.gradient-background::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background:
            radial-gradient(ellipse 120% 80% at 0% 100%, rgba(0,0,0,1) 0%, rgba(0,0,0,0.98) 10%, rgba(0,0,0,0.95) 20%, rgba(0,0,0,0.9) 30%, rgba(0,0,0,0.8) 40%, rgba(0,0,0,0.65) 50%, rgba(0,0,0,0.5) 60%, rgba(0,0,0,0.3) 70%, transparent 85%),
            radial-gradient(ellipse 120% 80% at 100% 0%, rgba(0,0,0,1) 0%, rgba(0,0,0,0.98) 10%, rgba(0,0,0,0.95) 20%, rgba(0,0,0,0.9) 30%, rgba(0,0,0,0.8) 40%, rgba(0,0,0,0.65) 50%, rgba(0,0,0,0.5) 60%, rgba(0,0,0,0.3) 70%, transparent 85%),
            radial-gradient(ellipse 600% 200% at 50% 50%, transparent 0%, transparent 10%, rgba(0,0,0,0.25) 25%, rgba(0,0,0,0.5) 35%, rgba(0,0,0,0.65) 40%, rgba(0,0,0,0.75) 45%, rgba(0,0,0,0.8) 50%, rgba(0,0,0,0.75) 55%, rgba(0,0,0,0.65) 60%, rgba(0,0,0,0.5) 65%, rgba(0,0,0,0.25) 75%, transparent 90%, transparent 100%),
            linear-gradient(135deg, transparent 0%, rgba(0,0,0,0.35) 25%, rgba(0,0,0,0.6) 50%, rgba(0,0,0,0.35) 75%, transparent 100%);
        pointer-events: none;
        z-index: -1;
    }
}

body {
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 14px;
    color: light-dark(#1D2324, #EBEFF0);
    min-height: 100vh;
}

body>main {
    padding: 0;
    display: flex;
    min-height: 100vh;
    justify-content: center;
}

.content-wrapper {
    width: 800px;
    max-width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-flow: column wrap;
}

.content-wrapper.register main.page-body {
    width: 710px;
    max-width: 100%;
}

main.page-body {
    width: 430px;
    max-width: 100%;
    padding: 0;
}

.panel {
    background: light-dark(#ffffff, #1D2324);
    border: none;
    color: light-dark(#1D2324, #EBEFF0);
    border-radius: 8px;
    box-shadow: none;
    border-top: none;
    padding: 2rem 1.5rem 1rem 1.5rem;
}

.panel h2 {
    margin: 0.25rem 0 0.5rem 0;
    color: light-dark(#1D2324, #EBEFF0);
    font-size: 24px;
    padding: 0 0 20px 0;
}

.panel>main {
    padding: 0;
}

.panel a {
    color: light-dark(#1D2324, #EBEFF0) !important;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.panel a:hover {
    color: light-dark(#1D2324, #EBEFF0) !important;
}

.montel-logo {
    width: 100%;
    margin-bottom: 30px;
    margin-top: 20px;
}


.montel-logo svg path {
    fill: light-dark(#01796E, #EBEFF0);
}

.text-center {
    text-align: center;
}

.form-title-with-icon {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 16px;
    margin-bottom: 1.5rem;
}

.form-title-with-icon h2 {
    margin: 0;
    padding: 0;
}

.login-subtitle {
    margin: 2px 0 0 0;
    font-size: 13px;
    color: light-dark(#596C6E, #9AADAF);
    font-weight: 400;
    line-height: 1.4;
}

.application-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 8px;
    background: linear-gradient(45deg, #B7E6E6 0%, #C1C0FC 100%);
    font-size: 28px;
    color: #01796E;
    flex-shrink: 0;
}


.application-icon--admin {
    background: #01796E;
    color: #EBEFF0;
}

form {
    width: 100%;
}

form fieldset {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    border: none;
    padding: 0;
    margin: 0;
}

.form-row {
    margin-bottom: 1.25rem;
    width: 100%;
}

.form-row>label:first-of-type {
    margin-bottom: 0.5rem;
}

label {
    display: block;
    font-size: 16px;
    font-weight: normal;
    line-height: 1.5rem;
    color: light-dark(#596C6E, #9AADAF);
}

input {
    border: 1px solid light-dark(#B9C7C9, #596C6E) !important;
    border-radius: 4px !important;
    background-color: transparent !important;
    color: light-dark(#1D2324, #EBEFF0);
    font-size: 18px !important;
    padding: 9px 12px !important;
    line-height: 22px !important;
    box-shadow: none !important;
    width: 100%;
    font-family: 'Roboto', sans-serif;
    outline: none;
}

input::placeholder {
    color: light-dark(#596C6E, #9AADAF) !important;
    font-size: 18px !important;
}

input:hover {
    border-color: light-dark(#7A9496, #7A9496) !important;
}

input:focus {
    border-color: light-dark(#7A9496, #7A9496) !important;
}

.button.blue {
    background-color: light-dark(#01796E, #01796E) !important;
    padding: 0px 16px 2px 16px !important;
    border-radius: 24px !important;
    font-size: 16px !important;
    height: 40px !important;
    min-width: 168px !important;
    font-weight: 600 !important;
    color: light-dark(#EBEFF0, #EBEFF0) !important;
    border: none;
    cursor: pointer;
    font-family: 'Roboto', sans-serif;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    transition: background-color 0.2s ease;
}

.button.blue:hover {
    background-color: light-dark(#4DA199, #4DA199) !important;
}

.button.blue:active {
    background-color: light-dark(#4DA199, #4DA199) !important;
}

.button.blue:focus {
    background-color: light-dark(#4DA199, #4DA199) !important;
}

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

.button-spinner {
    display: none;
    position: absolute;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

.button.blue.loading .button-text {
    opacity: 0;
}

.button.blue.loading .button-spinner {
    display: block;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.forgot-password-link {
    float: right;
    margin-top: 1rem;
}

.hr-container {
    padding: 1em 0;
    position: relative;
    text-align: center;
}

.hr-container > div {
    color: light-dark(#6c757d, #ACB5B9) !important;
    background: light-dark(#ffffff, #1D2324) !important;
    position: relative;
    display: inline-block;
    padding: 0 10px;
    z-index: 1;
}

.hr-container > hr {
    border: none;
    border-top: 1px solid light-dark(#dee2e6, #ACB5B9) !important;
    margin: 0;
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
}

.centered {
    text-align: center;
}

.mb-3 {
    margin-bottom: 1rem;
}

.password-wrapper {
    position: relative;
}

.password-icon {
    color: light-dark(#596C6E, #9AADAF);
    position: absolute;
    right: 15px;
    top: 6px;
    cursor: pointer;
    width: 25px;
    height: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.password-icon svg {
    width: 35px;
    height: 25px;
}

.password-icon-hide svg path {
    fill: light-dark(#5B7B7E, #9AADAF);
}

.password-icon-show svg path {
    fill: light-dark(#ACB5B9, #596C6E);
}

.password-icon-hide {
    display: none;
}

.password-icon-show {
    display: inline-flex;
}

span.error {
    display: none;
    margin-top: 4px;
    color: light-dark(#BB4258, #BB4258);
    font-size: 12px;
}

span.error.visible {
    display: block;
}

.error.general-error {
    display: none;
    padding: 10px 12px;
    background: rgba(187, 66, 88, 0.1);
    border-radius: 4px;
    text-align: center;
    font-size: 14px;
    margin-bottom: 1rem;
    color: light-dark(#BB4258, #BB4258);
}

.error.general-error.visible {
    display: block;
}

input.error-input {
    border-color: light-dark(#BB4258, #BB4258) !important;
}

@keyframes fadeOut {
    from {
        opacity: 1;
        transform: scale(1);
    }
    to {
        opacity: 0;
        transform: scale(0.95);
    }
}

form.success {
    animation: fadeOut 0.3s ease forwards;
}

@media (max-width: 768px) {
    body>main {
        padding: 20px;
    }

    .content-wrapper {
        width: 100%;
    }

    main.page-body {
        width: 100%;
    }

    .panel {
        padding: 1.5rem 1rem 1rem 1rem;
    }

    .panel h2 {
        font-size: 20px;
    }

    .montel-logo {
        margin-bottom: 20px;
        margin-top: 10px;
    }

    .montel-logo svg {
        width: 240px;
        height: auto;
    }
}

@media (max-width: 480px) {
    body>main {
        padding: 12px;
    }

    .panel {
        padding: 1.25rem 1rem 1rem 1rem;
    }

    .montel-logo svg {
        width: 200px;
    }

    .application-icon {
        width: 40px;
        height: 40px;
        font-size: 24px;
    }

    .panel h2 {
        font-size: 18px;
    }

    input {
        font-size: 16px !important;
    }

    .button.blue {
        font-size: 14px !important;
        min-width: 140px !important;
    }
}

.row {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 80px;
    align-items: flex-start;
    width: 100%;
}

.column {
    flex: 1;
    min-width: 0;
}

@media (max-width: 768px) {
    .row {
        flex-wrap: wrap;
        gap: 0;
    }

    .column {
        width: 100%;
    }
}

.full-width {
    width: 100%;
}

.required {
    color: light-dark(#01796E, #50A8A0);
}

.checkbox-list {
    background: none;
    border: none;
    box-shadow: none;
    padding: 0;
}

.checkbox {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    position: relative;
    cursor: pointer;
}

.checkbox input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    width: 18px;
    height: 18px;
    margin: 0;
}

.checkbox .box {
    position: relative;
    display: inline-block;
    width: 18px;
    height: 18px;
    background: none;
    border: 2px solid light-dark(#1D2324, #EBEFF0);
    border-radius: 2px;
    flex-shrink: 0;
    margin-top: 3px;
    transition: all 0.2s ease;
}

.checkbox input[type="checkbox"]:checked + .box {
    border-color: light-dark(#1D2324, #EBEFF0);
    background: none;
}

.checkbox input[type="checkbox"]:checked + .box::after {
    content: '';
    position: absolute;
    left: 1px;
    top: 2px;
    width: 13px;
    height: 5px;
    border: solid light-dark(#1D2324, #EBEFF0);
    border-width: 0 0 2px 2px;
    transform: rotate(-45deg);
}

.checkbox .label {
    flex: 1;
    color: light-dark(#1D2324, #EBEFF0);
    font-size: 14px;
    line-height: 1.5;
    cursor: pointer;
}

.checkbox .label a {
    color: light-dark(#1D2324, #EBEFF0) !important;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.checkbox input[type="checkbox"]:hover + .box {
    border-color: light-dark(#01796E, #50A8A0);
}

.checkbox input[type="checkbox"]:focus + .box {
    outline: 2px solid light-dark(#01796E, #50A8A0);
    outline-offset: 2px;
}

.container {
    width: 100%;
}

h3.section-header {
    font-weight: 700;
    font-size: 20px;
    color: light-dark(#495057, #dfdfdf);
    margin-bottom: 0.5rem;
    margin-top: 0;
}

h3.section-header.mt-2 {
    margin-top: 2.25rem;
}

.form-footer {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    margin: 1.5rem 0 0 0;
    gap: 16px;
}

.form-footer p {
    margin: 0;
    font-size: 14px;
    line-height: 20px;
    color: light-dark(#596C6E, #9AADAF);
}

label.select {
    width: 100%;
    display: block;
    position: relative;
}

label.select select {
    border: 1px solid light-dark(#B9C7C9, #596C6E) !important;
    border-radius: 4px !important;
    background-color: transparent !important;
    color: light-dark(#1D2324, #EBEFF0);
    font-size: 18px !important;
    padding: 9px 12px !important;
    line-height: 22px !important;
    box-shadow: none !important;
    min-height: 2.5rem;
    width: 100%;
    font-family: 'Roboto', sans-serif;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L6 6L11 1' stroke='%235B7B7E' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 40px !important;
}

label.select select::placeholder {
    color: light-dark(#596C6E, #9AADAF) !important;
    font-size: 18px !important;
}

label.select select:hover {
    border-color: light-dark(#7A9496, #7A9496) !important;
}

label.select select:focus {
    border-color: light-dark(#7A9496, #7A9496) !important;
    outline: none;
}

label.select select option:disabled {
    color: light-dark(#596C6E, #9AADAF) !important;
}

label.select.error select {
    border-color: light-dark(#BB4258, #BB4258) !important;
}

.consent-section {
    margin-top: 2.25rem;
}

.push-less-top {
    margin-top: 0.5rem;
}

.mt-2 {
    margin-top: 1rem;
}

.success-message {
    display: none;
    padding: 10px 12px;
    background: rgba(1, 121, 110, 0.1);
    border-radius: 4px;
    text-align: center;
    font-size: 14px;
    margin-bottom: 1rem;
    color: light-dark(#01796E, #50A8A0);
}

.success-message.visible {
    display: block;
}

.panel > h2:first-child {
    margin-top: 0;
}

.panel p {
    color: light-dark(#596C6E, #9AADAF);
    line-height: 1.5;
    margin-bottom: 1rem;
}

.text-align-end {
    text-align: end;
}

@media (max-width: 768px) {
    .row {
        gap: 0 !important;
    }

    .form-footer {
        flex-direction: column;
        align-items: flex-start;
    }

    h3.section-header.mt-2 {
        margin-top: 1.5rem;
    }
}
