﻿/* =========================================================
   CMS LOGIN POPUP
   Bottom -> Top Animation
========================================================= */

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}


/* =========================================================
   OVERLAY
========================================================= */

.cms-login-wrapper {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100vh;
    z-index: 99999;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    background: rgba(7, 27, 53, 0.65);
    overflow: hidden;
    opacity: 1;
}


/* =========================================================
   LOGIN POPUP
========================================================= */

.cms-login-section {
    position: relative;
    width: 100%;
    max-width: 520px;
    background: #ffffff;
    border-radius: 28px 28px 0 0;
    box-shadow: 0 -15px 50px rgba(0, 0, 0, 0.30);
    max-height: 92vh;
    overflow-y: auto;
    /* IMPORTANT */

    transform: translateY(100%);
    animation: loginPopupOpen 0.65s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}


/* =========================================================
   BOTTOM -> TOP ANIMATION
========================================================= */

@keyframes loginPopupOpen {

    0% {
        transform: translateY(100%);
    }

    100% {
        transform: translateY(0);
    }
}


/* =========================================================
   TOP HANDLE
========================================================= */

.cms-login-section::before {
    content: "";
    display: block;
    width: 55px;
    height: 5px;
    margin: 12px auto 4px;
    border-radius: 10px;
    background: #c89420;
}


/* =========================================================
   CLOSE BUTTON
========================================================= */

.cms-close-btn {
    position: absolute;
    top: 15px;
    right: 18px;
    width: 38px;
    height: 38px;
    border: none;
    border-radius: 50%;
    background: #f5f5f5;
    color: #071b35;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
    cursor: pointer;
    z-index: 20;
    transition: all 0.25s ease;
}

    .cms-close-btn:hover {
        background: #c89420;
        color: #ffffff;
        transform: rotate(90deg);
    }


/* =========================================================
   LOGIN CONTAINER
========================================================= */

.login-container {
    width: 100%;
    padding: 30px 38px 35px;
}


/* =========================================================
   LEFT BRAND HIDE
========================================================= */

.cms-brand-section {
    display: none;
}


/* =========================================================
   MOBILE LOGO
========================================================= */

.mobile-logo {
    text-align: center;
    margin-bottom: 12px;
}

    .mobile-logo img {
        width: 125px;
        height: auto;
    }


/* =========================================================
   HEADING
========================================================= */

.login-heading {
    text-align: center;
    margin-bottom: 25px;
}

.login-small-title {
    display: block;
    color: #c89420;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 5px;
}

.login-heading h2 {
    margin: 0;
    color: #071b35;
    font-family: "Cormorant Garamond", serif;
    font-size: 38px;
    font-weight: 700;
}

.login-heading p {
    margin: 5px 0 0;
    color: #777;
    font-size: 14px;
}


/* =========================================================
   FORM
========================================================= */

.form-group {
    margin-bottom: 19px;
}

    .form-group label {
        display: block;
        margin-bottom: 7px;
        color: #071b35;
        font-size: 14px;
        font-weight: 600;
    }


/* =========================================================
   INPUT
========================================================= */

.input-wrapper {
    position: relative;
}

    .input-wrapper > i:first-child {
        position: absolute;
        left: 16px;
        top: 50%;
        transform: translateY(-50%);
        color: #c89420;
        z-index: 2;
    }

    .input-wrapper .form-control {
        height: 52px;
        padding-left: 48px;
        padding-right: 45px;
        border: 1px solid #dddddd;
        border-radius: 12px;
        font-family: "Montserrat", sans-serif;
        font-size: 14px;
        box-shadow: none;
    }

        .input-wrapper .form-control:focus {
            border-color: #c89420;
            box-shadow: 0 0 0 3px rgba(200, 148, 32, 0.12);
        }


/* =========================================================
   PASSWORD
========================================================= */

.password-label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

    .password-label-row a {
        color: #c89420;
        font-size: 12px;
        text-decoration: none;
    }

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    border: none;
    background: transparent;
    color: #777;
    cursor: pointer;
}


/* =========================================================
   REMEMBER ME
========================================================= */

.login-options {
    margin: 5px 0 20px;
}

.remember-box {
    display: flex !important;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

    .remember-box input {
        accent-color: #c89420;
    }


/* =========================================================
   LOGIN BUTTON
========================================================= */

.login-submit {
    width: 100%;
    height: 54px;
    border: none;
    border-radius: 12px;
    background: linear-gradient( 135deg, #d9a52e, #b98214 );
    color: #ffffff;
    font-size: 15px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

    .login-submit:hover {
        transform: translateY(-2px);
        box-shadow: 0 8px 22px rgba(185, 130, 20, 0.30);
    }


/* =========================================================
   SECURITY
========================================================= */

.login-security {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    color: #777;
    font-size: 12px;
}

    .login-security i {
        color: #c89420;
    }


/* =========================================================
   BACK TO WEBSITE
========================================================= */

.back-website {
    display: block;
    margin-top: 17px;
    text-align: center;
    color: #071b35;
    font-size: 13px;
    text-decoration: none;
}

    .back-website:hover {
        color: #c89420;
    }


/* =========================================================
   ERROR
========================================================= */

.login-error {
    display: flex;
    gap: 10px;
    padding: 12px;
    margin-bottom: 18px;
    border-radius: 10px;
    background: #fff1f1;
    color: #c62828;
    font-size: 13px;
}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 576px) {

    .cms-login-section {
        max-width: 100%;
        max-height: 94vh;
        border-radius: 24px 24px 0 0;
    }

    .login-container {
        padding: 28px 22px 30px;
    }

    .login-heading h2 {
        font-size: 33px;
    }

    .mobile-logo img {
        width: 110px;
    }
}


/* =========================================================
   REDUCED MOTION
========================================================= */

@media (prefers-reduced-motion: reduce) {

    .cms-login-section {
        animation: none;
        transform: translateY(0);
    }
}

/* ==========================================
   CMS LOGIN POPUP
========================================== */

.cms-login-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: none;
    align-items: flex-end;
    justify-content: center;
}

    .cms-login-modal.active {
        display: flex;
    }


/* Dark overlay */

.cms-login-overlay {
    position: absolute;
    inset: 0;
    background: rgba(5, 20, 40, 0.65);
    backdrop-filter: blur(3px);
    animation: cmsOverlayIn .25s ease;
}


/* Popup */

.cms-login-popup {
    position: relative;
    z-index: 2;
    width: min(560px, 100%);
    max-height: 92vh;
    overflow-y: auto;
    background: #fff;
    border-radius: 28px 28px 0 0;
    box-shadow: 0 -10px 40px rgba(0,0,0,.25);
    transform: translateY(100%);
    animation: cmsPopupUp .45s cubic-bezier(.22,.61,.36,1) forwards;
}


/* Close */

.cms-close-btn {
    position: absolute;
    right: 18px;
    top: 18px;
    width: 42px;
    height: 42px;
    border: none;
    border-radius: 50%;
    background: #f7f7f7;
    color: #102844;
    font-size: 17px;
    z-index: 10;
    cursor: pointer;
}

    .cms-close-btn:hover {
        background: #c99518;
        color: #fff;
    }


/* Animations */

@keyframes cmsPopupUp {

    from {
        transform: translateY(100%);
    }

    to {
        transform: translateY(0);
    }
}

@keyframes cmsOverlayIn {

    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}


/* Mobile */

@media(max-width:600px) {

    .cms-login-popup {
        width: 100%;
        max-height: 94vh;
        border-radius: 24px 24px 0 0;
    }
}