/*
 * NIF_AUTH_HOME_DESIGN_V1
 * Blue and gold authentication design.
 */

:root {
    --nif-auth-navy: #061632;
    --nif-auth-navy-light: #0d2b5e;
    --nif-auth-blue: #315fe8;
    --nif-auth-blue-light: #5b7cf1;

    --nif-auth-gold: #f2b500;
    --nif-auth-gold-light: #ffe279;
    --nif-auth-gold-dark: #c88900;

    --nif-auth-text: #14233d;
    --nif-auth-muted: #6f7b90;
}

/* ==================================================
   FULL PAGE
   ================================================== */

html,
body {
    min-height: 100%;
}

body,
body.auth-body-bg {
    position: relative;
    min-height: 100vh;
    margin: 0;

    background:
        radial-gradient(
            circle at 12% 12%,
            rgba(64, 103, 232, 0.35),
            transparent 30%
        ),
        radial-gradient(
            circle at 88% 18%,
            rgba(240, 180, 0, 0.18),
            transparent 25%
        ),
        radial-gradient(
            circle at 75% 88%,
            rgba(47, 90, 220, 0.25),
            transparent 30%
        ),
        linear-gradient(
            145deg,
            #041127 0%,
            #071b3d 48%,
            #0a2550 100%
        ) !important;

    background-attachment: fixed !important;
    overflow-x: hidden;
}

/* Background decoration */

body::before,
body::after {
    content: "";
    position: fixed;
    pointer-events: none;
    border-radius: 999px;
    z-index: 0;
    filter: blur(4px);
}

body::before {
    width: 310px;
    height: 310px;
    top: -140px;
    left: -100px;

    border: 1px solid rgba(255, 215, 90, 0.25);
    box-shadow:
        0 0 90px rgba(255, 203, 40, 0.10),
        inset 0 0 60px rgba(255, 255, 255, 0.04);
}

body::after {
    width: 430px;
    height: 430px;
    right: -230px;
    bottom: -230px;

    border: 1px solid rgba(92, 126, 241, 0.35);
    box-shadow:
        0 0 100px rgba(54, 96, 226, 0.18),
        inset 0 0 60px rgba(255, 255, 255, 0.04);
}

/* ==================================================
   PAGE POSITION
   ================================================== */

.account-pages {
    position: relative;
    z-index: 2;

    display: flex;
    align-items: center;

    min-height: 100vh;
    margin: 0 !important;
    padding: 80px 14px 45px !important;
}

.account-pages > .container {
    width: 100%;
}

.account-pages .col-md-8,
.account-pages .col-lg-6,
.account-pages .col-xl-5 {
    width: 100%;
    max-width: 570px;
    flex: 0 0 100%;
}

/* ==================================================
   AUTH CARD
   ================================================== */

.account-pages .card {
    position: relative;

    border: 1px solid rgba(255, 255, 255, 0.56) !important;
    border-radius: 26px !important;

    background: rgba(255, 255, 255, 0.985) !important;

    box-shadow:
        0 32px 75px rgba(0, 7, 30, 0.38),
        0 8px 25px rgba(0, 18, 62, 0.22),
        inset 0 1px 0 rgba(255, 255, 255, 0.9) !important;

    overflow: hidden !important;
}

.account-pages .card::before {
    content: "";
    position: absolute;
    z-index: 5;

    top: 0;
    left: 12%;
    right: 12%;
    height: 3px;

    border-radius: 0 0 10px 10px;

    background: linear-gradient(
        90deg,
        transparent,
        var(--nif-auth-gold),
        var(--nif-auth-gold-light),
        var(--nif-auth-gold),
        transparent
    );

    box-shadow: 0 0 22px rgba(244, 184, 0, 0.8);
}

/* ==================================================
   TOP ILLUSTRATION SECTION
   ================================================== */

.account-pages .bg-soft-primary {
    position: relative;
    min-height: 158px;

    background:
        radial-gradient(
            circle at 80% 25%,
            rgba(255, 210, 64, 0.24),
            transparent 30%
        ),
        linear-gradient(
            135deg,
            #0b2450 0%,
            #123a7c 55%,
            #315fe8 100%
        ) !important;

    overflow: hidden;
}

.account-pages .bg-soft-primary::before {
    content: "";
    position: absolute;

    width: 200px;
    height: 200px;

    top: -125px;
    right: -40px;

    border: 1px solid rgba(255, 222, 110, 0.34);
    border-radius: 50%;

    box-shadow: 0 0 50px rgba(255, 202, 25, 0.15);
}

.account-pages .bg-soft-primary::after {
    content: "";
    position: absolute;

    left: -50px;
    bottom: -110px;

    width: 200px;
    height: 200px;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.05);
}

.account-pages .bg-soft-primary .row {
    position: relative;
    z-index: 2;
    min-height: 158px;
}

.account-pages .bg-soft-primary .text-primary {
    padding: 28px 16px 28px 30px !important;
    color: #ffffff !important;
}

.account-pages .bg-soft-primary h5 {
    margin-bottom: 8px !important;

    color: #ffffff !important;
    font-size: 23px !important;
    font-weight: 800 !important;
    letter-spacing: -0.02em;
}

.account-pages .bg-soft-primary p {
    max-width: 250px;
    margin: 0 !important;

    color: rgba(255, 255, 255, 0.78) !important;
    font-size: 14px !important;
    line-height: 1.55 !important;
}

.account-pages .bg-soft-primary img {
    position: relative;
    z-index: 3;

    max-height: 145px;
    width: auto;

    filter:
        drop-shadow(0 15px 18px rgba(0, 12, 45, 0.20))
        saturate(1.03);
}

/* ==================================================
   LOGO AVATAR
   ================================================== */

.account-pages .profile-user-wid {
    position: relative;
    z-index: 10;
}

.account-pages .avatar-md {
    width: 82px !important;
    height: 82px !important;
}

.account-pages .avatar-title {
    width: 82px !important;
    height: 82px !important;

    border: 5px solid #ffffff !important;

    background:
        linear-gradient(
            145deg,
            #ffffff,
            #f1f5ff
        ) !important;

    box-shadow:
        0 10px 25px rgba(5, 29, 79, 0.18),
        0 0 0 1px rgba(47, 91, 222, 0.08),
        0 0 22px rgba(244, 181, 0, 0.18);
}

.account-pages .avatar-title img {
    max-width: 54px !important;
    max-height: 54px !important;
}

/* ==================================================
   CARD BODY
   ================================================== */

.account-pages .card-body {
    padding: 0 34px 34px !important;
}

.account-pages .card-body.pt-0 {
    padding-top: 0 !important;
}

.account-pages form {
    margin-top: 4px;
}

.account-pages .form-group {
    margin-bottom: 18px !important;
}

.account-pages label {
    margin-bottom: 8px;

    color: var(--nif-auth-text) !important;
    font-size: 14px;
    font-weight: 700;
}

/* ==================================================
   INPUTS AND SELECTS
   ================================================== */

.account-pages .form-control,
.account-pages select.form-control {
    width: 100%;
    height: 53px !important;

    padding-left: 16px;
    padding-right: 16px;

    border: 1px solid #d7deea !important;
    border-radius: 12px !important;

    color: var(--nif-auth-text) !important;
    background-color: #ffffff !important;

    font-size: 15px;

    box-shadow:
        inset 0 1px 2px rgba(20, 39, 80, 0.03),
        0 4px 12px rgba(29, 54, 104, 0.035);

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.account-pages textarea.form-control {
    min-height: 110px !important;
    height: auto !important;
}

.account-pages .form-control::placeholder {
    color: #9ca6b7 !important;
}

.account-pages .form-control:hover,
.account-pages select.form-control:hover {
    border-color: #aab9d4 !important;
}

.account-pages .form-control:focus,
.account-pages select.form-control:focus {
    border-color: var(--nif-auth-blue) !important;

    box-shadow:
        0 0 0 4px rgba(49, 95, 232, 0.12),
        0 8px 20px rgba(29, 68, 166, 0.08) !important;

    outline: none !important;
    transform: translateY(-1px);
}

/* Password browser autofill */

.account-pages input:-webkit-autofill,
.account-pages input:-webkit-autofill:hover,
.account-pages input:-webkit-autofill:focus {
    -webkit-text-fill-color: var(--nif-auth-text);
    -webkit-box-shadow: 0 0 0 1000px #ffffff inset !important;
    transition: background-color 9999s ease-in-out 0s;
}

/* ==================================================
   GOLD SUBMIT BUTTON
   ================================================== */

.account-pages .btn-primary,
.account-pages button[type="submit"] {
    position: relative;

    min-height: 54px;
    width: 100%;

    border: 1px solid #ffd95e !important;
    border-radius: 13px !important;

    color: #271b00 !important;

    background:
        linear-gradient(
            110deg,
            #d99400 0%,
            #f3b500 25%,
            #ffe16d 50%,
            #eda900 72%,
            #ca8200 100%
        ) !important;

    background-size: 220% 100% !important;

    font-size: 16px !important;
    font-weight: 800 !important;
    letter-spacing: 0.01em;

    text-shadow: 0 1px rgba(255, 255, 255, 0.42);

    box-shadow:
        0 10px 24px rgba(224, 155, 0, 0.32),
        0 0 22px rgba(255, 198, 23, 0.22),
        inset 0 1px 0 rgba(255, 255, 255, 0.72),
        inset 0 -1px 0 rgba(119, 69, 0, 0.20) !important;

    animation: nifAuthGoldShine 3.2s linear infinite;

    transition:
        transform 0.18s ease,
        box-shadow 0.18s ease,
        filter 0.18s ease;
}

.account-pages .btn-primary:hover,
.account-pages button[type="submit"]:hover {
    color: #171000 !important;

    transform: translateY(-2px);

    filter: brightness(1.04);

    box-shadow:
        0 15px 32px rgba(224, 155, 0, 0.38),
        0 0 30px rgba(255, 198, 23, 0.33),
        inset 0 1px 0 rgba(255, 255, 255, 0.8) !important;
}

.account-pages .btn-primary:active,
.account-pages button[type="submit"]:active {
    transform: translateY(0) scale(0.995);
}

.account-pages .btn-primary:focus,
.account-pages button[type="submit"]:focus {
    box-shadow:
        0 0 0 4px rgba(255, 195, 25, 0.22),
        0 12px 27px rgba(224, 155, 0, 0.33) !important;
}

@keyframes nifAuthGoldShine {
    0% {
        background-position: 210% 0;
    }

    100% {
        background-position: -20% 0;
    }
}

/* Respect reduced motion */

@media (prefers-reduced-motion: reduce) {
    .account-pages .btn-primary,
    .account-pages button[type="submit"] {
        animation: none !important;
    }
}

/* ==================================================
   LINKS AND FORGOT PASSWORD
   ================================================== */

.account-pages a {
    color: #c88400;
    font-weight: 700;
    text-decoration: none;

    transition:
        color 0.18s ease,
        opacity 0.18s ease;
}

.account-pages a:hover {
    color: #e3a400;
    text-decoration: none;
}

.account-pages .text-muted {
    color: var(--nif-auth-muted) !important;
}

.account-pages .text-center p {
    color: rgba(255, 255, 255, 0.78);
}

.account-pages .card .text-center p,
.account-pages .card p {
    color: var(--nif-auth-muted);
}

.account-pages .mdi-lock,
.account-pages .fa-lock,
.account-pages .fas.fa-lock {
    color: #a77700 !important;
}

/* ==================================================
   CAPTCHA
   ================================================== */

.account-pages .g-recaptcha,
.account-pages .h-captcha {
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
}

.account-pages iframe {
    max-width: 100%;
}

/* Captcha selector */

.account-pages select.form-control {
    cursor: pointer;
}

/* ==================================================
   HOME BUTTON
   ================================================== */

.home-btn {
    position: fixed !important;
    z-index: 20;

    top: 20px !important;
    right: 22px !important;
}

.home-btn a {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 48px;
    height: 48px;

    border: 1px solid rgba(255, 220, 105, 0.42);
    border-radius: 14px;

    color: #ffe17a !important;

    background: rgba(8, 27, 62, 0.72);

    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);

    box-shadow:
        0 10px 25px rgba(0, 7, 27, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.12),
        0 0 22px rgba(255, 193, 20, 0.10);

    transition:
        transform 0.18s ease,
        background 0.18s ease,
        box-shadow 0.18s ease;
}

.home-btn a:hover {
    color: #fff2b4 !important;
    background: rgba(17, 52, 112, 0.92);

    transform: translateY(-2px);

    box-shadow:
        0 14px 30px rgba(0, 7, 27, 0.34),
        0 0 25px rgba(255, 193, 20, 0.20);
}

.home-btn a i {
    margin: 0 !important;
    font-size: 22px !important;
}

/* ==================================================
   ALERTS
   ================================================== */

.account-pages .alert {
    border: 0 !important;
    border-radius: 12px !important;
    line-height: 1.5;

    box-shadow: 0 7px 20px rgba(25, 48, 91, 0.08);
}

.account-pages .alert-danger {
    color: #8d252b !important;
    background: #fff0f1 !important;
}

.account-pages .alert-success {
    color: #156d45 !important;
    background: #eaf9f1 !important;
}

/* ==================================================
   RESPONSIVE
   ================================================== */

@media (max-height: 900px) {
    .account-pages {
        align-items: flex-start;
    }
}

@media (max-width: 767.98px) {
    .account-pages {
        align-items: flex-start;

        min-height: 100vh;
        padding: 70px 10px 30px !important;
    }

    .account-pages .card {
        border-radius: 20px !important;
    }

    .account-pages .card-body {
        padding-left: 22px !important;
        padding-right: 22px !important;
        padding-bottom: 27px !important;
    }

    .account-pages .bg-soft-primary {
        min-height: 145px;
    }

    .account-pages .bg-soft-primary .row {
        min-height: 145px;
    }

    .account-pages .bg-soft-primary .text-primary {
        padding:
            24px
            8px
            23px
            22px !important;
    }

    .account-pages .bg-soft-primary h5 {
        font-size: 20px !important;
    }

    .account-pages .bg-soft-primary p {
        font-size: 13px !important;
    }

    .account-pages .bg-soft-primary img {
        max-height: 125px;
    }

    .home-btn {
        top: 13px !important;
        right: 13px !important;
    }

    .home-btn a {
        width: 44px;
        height: 44px;
        border-radius: 12px;
    }
}

@media (max-width: 390px) {
    .account-pages {
        padding-left: 7px !important;
        padding-right: 7px !important;
    }

    .account-pages .card-body {
        padding-left: 17px !important;
        padding-right: 17px !important;
    }

    .account-pages .form-control,
    .account-pages select.form-control {
        height: 51px !important;
        font-size: 14px;
    }

    .account-pages .g-recaptcha {
        transform: scale(0.88);
        transform-origin: left top;
        margin-bottom: -13px;
    }
}

@media (max-width: 350px) {
    .account-pages .g-recaptcha {
        transform: scale(0.80);
        margin-bottom: -22px;
    }
}

/* NIF_AUTH_LAYOUT_SCROLL_V3_START */

/*
 * Login, Registration na Forgot Password.
 * Iyi code ikosora:
 * - horizontal overflow
 * - igice gisohoka hanze ya card
 * - page icika igihe umuntu akoze scroll
 * - card itari hagati neza
 */

html {
    width: 100% !important;
    min-height: 100% !important;
    height: auto !important;

    overflow-x: hidden !important;
    overflow-y: auto !important;

    scroll-behavior: smooth;
    scroll-padding-top: 24px;
}

body.nif-auth-page {
    width: 100% !important;

    min-height: 100vh !important;
    min-height: 100svh !important;
    min-height: 100dvh !important;

    height: auto !important;
    max-height: none !important;

    margin: 0 !important;

    position: relative !important;
    inset: auto !important;

    overflow-x: hidden !important;
    overflow-y: auto !important;

    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: auto;
    touch-action: pan-y;

    background:
        radial-gradient(
            circle at 15% 15%,
            rgba(85, 110, 230, .10),
            transparent 32%
        ),
        radial-gradient(
            circle at 85% 85%,
            rgba(240, 180, 35, .10),
            transparent 30%
        ),
        #f7f8fc;
}

body.nif-auth-page,
body.nif-auth-page *,
body.nif-auth-page *::before,
body.nif-auth-page *::after {
    box-sizing: border-box !important;
}

/*
 * Main page wrapper.
 * Container ikoresha margin:auto:
 * - page ntoya ikaja hagati
 * - page ndende igakora scroll ata gice giciwe.
 */
body.nif-auth-page .account-pages {
    width: 100% !important;

    min-height: 100vh !important;
    min-height: 100svh !important;
    min-height: 100dvh !important;

    height: auto !important;
    max-height: none !important;

    margin: 0 !important;

    padding-top: max(72px, env(safe-area-inset-top)) !important;
    padding-right: 14px !important;
    padding-bottom: max(48px, env(safe-area-inset-bottom)) !important;
    padding-left: 14px !important;

    position: relative !important;
    inset: auto !important;

    display: flex !important;
    align-items: stretch !important;
    justify-content: flex-start !important;

    overflow: visible !important;
}

body.nif-auth-page .account-pages > .container,
body.nif-auth-page .auth-page-wrapper > .container,
body.nif-auth-page .nif-auth-wrapper > .container {
    width: 100% !important;
    max-width: 100% !important;

    height: auto !important;
    max-height: none !important;

    margin-top: auto !important;
    margin-right: auto !important;
    margin-bottom: auto !important;
    margin-left: auto !important;

    padding-right: 0 !important;
    padding-left: 0 !important;

    overflow: visible !important;
}

/*
 * Kuraho Bootstrap negative margins zituma
 * agace kava hanze kuri mobile.
 */
body.nif-auth-page .account-pages .row.justify-content-center,
body.nif-auth-page .auth-page-wrapper .row.justify-content-center,
body.nif-auth-page .nif-auth-wrapper .row.justify-content-center {
    width: 100% !important;

    margin-right: 0 !important;
    margin-left: 0 !important;

    align-items: center !important;
}

/*
 * Column igumane width nziza.
 */
body.nif-auth-page .account-pages .row.justify-content-center > [class*="col-"],
body.nif-auth-page .auth-page-wrapper .row.justify-content-center > [class*="col-"],
body.nif-auth-page .nif-auth-wrapper .row.justify-content-center > [class*="col-"] {
    width: 100% !important;
    max-width: 560px !important;

    padding-right: 0 !important;
    padding-left: 0 !important;

    margin-right: auto !important;
    margin-left: auto !important;
}

/*
 * Main card.
 * Overflow hidden niyo ikuraho agace kasohoka.
 */
body.nif-auth-page .card {
    width: 100% !important;

    height: auto !important;
    max-height: none !important;

    margin-right: auto !important;
    margin-left: auto !important;

    border: 1px solid rgba(85, 110, 230, .10) !important;
    border-radius: 18px !important;

    overflow: hidden !important;

    background: #ffffff !important;

    box-shadow:
        0 18px 45px rgba(31, 45, 90, .10),
        0 4px 14px rgba(31, 45, 90, .06) !important;
}

/*
 * Header ya card.
 */
body.nif-auth-page .card .bg-soft-primary,
body.nif-auth-page .card .bg-primary,
body.nif-auth-page .card .auth-card-header,
body.nif-auth-page .card .nif-auth-header {
    position: relative !important;

    width: 100% !important;
    max-width: 100% !important;

    overflow: hidden !important;

    border-top-left-radius: 17px !important;
    border-top-right-radius: 17px !important;
}

body.nif-auth-page .card img {
    max-width: 100% !important;
    height: auto !important;
}

/*
 * Illustration yo hejuru ntisohoke muri card.
 */
body.nif-auth-page .card .row {
    max-width: 100% !important;
}

body.nif-auth-page .card .profile-user-wid,
body.nif-auth-page .card .avatar-md,
body.nif-auth-page .card .avatar-lg {
    position: relative !important;
    z-index: 2 !important;
}

/*
 * Card body.
 */
body.nif-auth-page .card-body {
    width: 100% !important;
    height: auto !important;

    padding: 34px 34px 30px !important;

    overflow: visible !important;
}

body.nif-auth-page form {
    width: 100% !important;
    height: auto !important;

    margin: 0 !important;

    overflow: visible !important;
}

body.nif-auth-page .form-group,
body.nif-auth-page .mb-3,
body.nif-auth-page .mb-4 {
    width: 100% !important;
    height: auto !important;
}

body.nif-auth-page .form-control,
body.nif-auth-page select.form-control,
body.nif-auth-page input.form-control {
    width: 100% !important;
    max-width: 100% !important;

    min-height: 46px !important;

    border-radius: 9px !important;
}

/*
 * Buttons zigume mu card neza.
 */
body.nif-auth-page button,
body.nif-auth-page .btn {
    max-width: 100% !important;
}

body.nif-auth-page form .btn-block,
body.nif-auth-page form .btn.w-100 {
    width: 100% !important;
    min-height: 46px !important;

    border-radius: 9px !important;
}

/*
 * Alerts ntizirenge card.
 */
body.nif-auth-page .alert {
    width: 100% !important;
    max-width: 100% !important;

    height: auto !important;

    white-space: normal !important;
    overflow-wrap: anywhere !important;
}

/*
 * Captcha.
 * JavaScript iri musi izayigabanya kuri phone ntoya.
 */
body.nif-auth-page .g-recaptcha {
    width: 304px;
    max-width: 304px;

    margin-right: auto !important;
    margin-left: auto !important;

    transform-origin: left top;
}

body.nif-auth-page iframe {
    max-width: 100% !important;
}

/*
 * Footer ntibe fixed.
 */
body.nif-auth-page footer,
body.nif-auth-page .footer,
body.nif-auth-page .auth-footer,
body.nif-auth-page .footer-bottom {
    width: 100% !important;

    height: auto !important;
    max-height: none !important;

    position: relative !important;
    inset: auto !important;

    margin-top: 26px !important;

    text-align: center !important;
}

/*
 * Home icon igume hejuru.
 */
body.nif-auth-page .home-btn {
    position: fixed !important;

    top: max(18px, env(safe-area-inset-top)) !important;
    right: 18px !important;

    z-index: 1050 !important;
}

/*
 * Mobile.
 */
@media (max-width: 575.98px) {
    body.nif-auth-page .account-pages {
        padding-top: max(68px, env(safe-area-inset-top)) !important;
        padding-right: 10px !important;
        padding-bottom: max(38px, env(safe-area-inset-bottom)) !important;
        padding-left: 10px !important;
    }

    body.nif-auth-page .card {
        max-width: 100% !important;
        border-radius: 15px !important;
    }

    body.nif-auth-page .card-body {
        padding: 28px 20px 25px !important;
    }

    body.nif-auth-page .card .bg-soft-primary,
    body.nif-auth-page .card .bg-primary,
    body.nif-auth-page .card .auth-card-header,
    body.nif-auth-page .card .nif-auth-header {
        border-top-left-radius: 14px !important;
        border-top-right-radius: 14px !important;
    }
}

/*
 * Phone ntoya cane.
 */
@media (max-width: 360px) {
    body.nif-auth-page .account-pages {
        padding-right: 7px !important;
        padding-left: 7px !important;
    }

    body.nif-auth-page .card-body {
        padding-right: 15px !important;
        padding-left: 15px !important;
    }
}

/*
 * Landscape mode.
 */
@media (orientation: landscape) and (max-height: 650px) {
    body.nif-auth-page .account-pages {
        padding-top: 30px !important;
        padding-bottom: 32px !important;
    }

    body.nif-auth-page .home-btn {
        position: absolute !important;
    }
}

/* NIF_AUTH_LAYOUT_SCROLL_V3_END */
