/* ============================================
   Login Container - Full page centered layout
   ============================================ */

.modern-login-container {
    min-height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    /* background: linear-gradient(135deg, #F5F3FF 0%, #F3F0FF 50%, #EEF2FF 100%); */
    position: relative;
    overflow: hidden;
}

/* Dark Mode Support */
body[data-theme-style="dark"] .modern-login-container {
    background-image:
        linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    background-size: 100% 100%;
    background-position: 0 0;
    background-repeat: repeat;
    background-attachment: fixed;
   
}

/* Decorative background shapes - SVG style */
.modern-login-container::before {
    content: '';
    position: fixed;
    top: -100px;
    left: -100px;
    width: 608px;
    height: 371px;
    background-image: url('data:image/svg+xml;utf8,<svg width="608" height="371" viewBox="0 0 608 371" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M607.671 66.6389V-82.3568H485.433V66.6389C485.433 166.908 404.105 248.236 303.836 248.236C203.566 248.236 122.238 166.908 122.238 66.6389V-209.595C122.238 -277.121 67.5269 -331.833 0 -331.833V66.7093C0 234.506 136.04 370.545 303.836 370.545C471.632 370.545 607.671 234.506 607.671 66.7093V66.6389Z" fill="url(%23paint0_linear_53_4209)"/><defs><linearGradient id="paint0_linear_53_4209" x1="1002.48" y1="987.722" x2="-126.534" y2="-540.399" gradientUnits="userSpaceOnUse"><stop stop-color="%235931F8"/><stop offset="0.5" stop-color="%234123FD"/><stop offset="1" stop-color="%2311BEFD"/></linearGradient></defs></svg>');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    z-index: 0;
    pointer-events: none;
    opacity: 0.1;
}

body[data-theme-style="dark"] .modern-login-container::before {
    opacity: 0.05;
    filter: brightness(0.6);
}

.modern-login-container::after {
    content: '';
    position: fixed;
    bottom: -80px;
    right: -500px;
    width: 617px;
    height: 261px;
    background-image: url('data:image/svg+xml;utf8,<svg width="617" height="261" viewBox="0 0 617 261" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M616.581 404.314V253.134H492.55V404.314C492.55 506.054 410.03 588.574 308.29 588.574C206.551 588.574 124.031 506.054 124.031 404.314V124.031C124.031 55.5137 68.5169 0 0 0V404.386C0 574.642 138.034 712.676 308.29 712.676C478.547 712.676 616.581 574.642 616.581 404.386V404.314Z" fill="url(%23paint0_linear_53_4222)"/><defs><linearGradient id="paint0_linear_53_4222" x1="1017.18" y1="1338.9" x2="-128.389" y2="-211.624" gradientUnits="userSpaceOnUse"><stop stop-color="%235931F8"/><stop offset="0.5" stop-color="%234123FD"/><stop offset="1" stop-color="%2311BEFD"/></linearGradient></defs></svg>');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    z-index: 0;
    pointer-events: none;
    opacity: 0.08;
}

body[data-theme-style="dark"] .modern-login-container::after {
    opacity: 0.04;
    filter: brightness(0.6);
}

/* Third decorative shape - Circle positioned at center right */
.modern-login-container {
    background-image:
        /* url('data:image/svg+xml;utf8,<svg width="124" height="124" viewBox="0 0 124 124" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M61.7296 123.459C95.8219 123.459 123.459 95.8218 123.459 61.7296C123.459 27.6373 95.8219 0 61.7296 0C27.6373 0 0 27.6373 0 61.7296C0 95.8218 27.6373 123.459 61.7296 123.459Z" fill="url(%23paint0_linear_53_4223)" opacity="0.15"/><defs><linearGradient id="paint0_linear_53_4223" x1="1128.06" y1="1505.09" x2="-17.5045" y2="-45.4396" gradientUnits="userSpaceOnUse"><stop stop-color="%235931F8"/><stop offset="0.5" stop-color="%234123FD"/><stop offset="1" stop-color="%2311BEFD"/></linearGradient></defs></svg>'), */
            linear-gradient(135deg, #F5F3FF 0%, #F3F0FF 50%, #EEF2FF 100%);
    background-size: 124px 124px, 100% 100%;
    background-position: 90% 50%, 0 0;
    background-repeat: no-repeat, repeat;
    background-attachment: fixed, scroll;
}

/* Ensure content is above decorative elements */
.modern-login-container > * {
    position: relative;
    /* z-index: 1; */
}

/* ============================================
   Login Wrapper
   ============================================ */

.login-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 140%;
    max-width: 120%;
    row-gap: 30px;
}

.login-wrapper .brand-logo {
    width: 140px;
    height: 132px;
}

/* ============================================
   Login Content
   ============================================ */

.login-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    align-self: stretch;
    row-gap: 10px;
}

/* ============================================
   Login Header
   ============================================ */

.login-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    align-self: stretch;
    margin: 0 5px;
    row-gap: 20px;
}

.login-title {
    align-self: stretch;
    text-align: center;
    line-height: 29px;
    letter-spacing: 0;
    color: #000;
    font-family: Tajawal, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", SimHei, Arial, Helvetica, sans-serif;
    font-size: 35px;
    font-weight: 700;
}

body[data-theme-style="dark"] .login-title {
    color: #FFFFFF;
}

.signup-subtext {
    align-self: stretch;
    text-align: center;
    line-height: 2px;
    letter-spacing: 0;
    color: #000;
    font-family: Tajawal, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", SimHei, Arial, Helvetica, sans-serif;
    font-size: 18px;
    font-weight: 500;
}

body[data-theme-style="dark"] .signup-subtext {
    color: #E0E0E0;
}

.signup-hint {
    line-height: 26px;
    letter-spacing: 0;
    color: #737789;
    font-family: Tajawal, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", SimHei, Arial, Helvetica, sans-serif;
    font-size: 24px;
    font-weight: 500;
}

body[data-theme-style="dark"] .signup-hint {
    color: #A0A0A0;
}

.signup-link {
    line-height: 26px;
    letter-spacing: 0;
    font-family: Tajawal, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", SimHei, Arial, Helvetica, sans-serif;
    font-size: 17px;
    font-weight: 500;
    color: #3883f4;
    text-decoration: none;
    transition: color 0.3s ease;
}

.signup-link:hover {
    color: #2563eb;
    text-decoration: underline;
}

body[data-theme-style="dark"] .signup-link {
    color: #5BA3FF;
}

body[data-theme-style="dark"] .signup-link:hover {
    color: #7BB8FF;
}

/* ============================================
   Login Card
   ============================================ */

.login-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    align-self: stretch;
    border-radius: 16px;
    background: #ffffff;
    padding: 50px;
    row-gap: 20px;
    backdrop-filter: blur(10px);
    border: 2px solid #d8b4ff;
    width: 120%;
    margin: 0 auto;
    margin-left: -8%;
    margin-right: -8%;
}

body[data-theme-style="dark"] .login-card {
    background: #1e293b;
    border: 2px solid #3d5a80;
    /* margin-left: -8%;
    margin-right: -8%; */
}

/* ============================================
   Form Fields
   ============================================ */

.field-label {
    line-height: 26px;
    letter-spacing: 0;
    color: #000;
    font-family: Tajawal, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", SimHei, Arial, Helvetica, sans-serif;
    font-size: 24px;
    font-weight: 500;
}

body[data-theme-style="dark"] .field-label {
    color: #FFFFFF;
}

.input-group {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    align-self: stretch;
    row-gap: 16px;
}

.input-box {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    align-self: stretch;
    justify-content: center;
    border-radius: 10px;
    box-shadow: 0 0 8px 0 #5931f81a;
    background: #fff;
    padding: 16px;
    height: 56px;
    row-gap: 10px;
    transition: box-shadow 0.3s ease, border 0.3s ease;
    border: 2px solid transparent;
}

body[data-theme-style="dark"] .input-box {
    background: #0f172a;
    box-shadow: 0 0 8px 0 #1660c133;
}

.input-box:hover {
    border: 2px solid #9b6dd4;
    box-shadow: 0 0 12px 0 #9b6dd4;
}

body[data-theme-style="dark"] .input-box:hover {
    border: 2px solid #5BA3FF;
    box-shadow: 0 0 12px 0 #5BA3FF;
}

.input-box:focus-within {
    border: 2px solid #3883f4;
    box-shadow: 0 0 16px 0 #3883f4;
}

body[data-theme-style="dark"] .input-box:focus-within {
    border: 2px solid #5BA3FF;
    box-shadow: 0 0 16px 0 #5BA3FF;
}

.input-box .form-control {
    border: none;
    box-shadow: none;
    padding: 0;
    height: auto;
    font-size: 20px;
    color: #404040;
}

body[data-theme-style="dark"] .input-box .form-control {
    background: #0f172a;
    color: #FFFFFF;
}

.input-box .form-control:focus {
    outline: none;
    box-shadow: none;
}

/* ============================================
   Password Section
   ============================================ */

.password-section {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    align-self: stretch;
    row-gap: 16px;
}

.password-group {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    align-self: stretch;
    row-gap: 16px;
}

.password-header {
    display: flex;
    align-items: flex-start;
    align-self: stretch;
    justify-content: space-between;
}

.password-toggle-icon {
    width: 24px;
    height: 24px;
    cursor: pointer;
    transition: opacity 0.3s ease;
}

.password-toggle-icon:hover {
    opacity: 0.7;
}

.password-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    align-self: stretch;
    justify-content: center;
    border-radius: 10px;
    box-shadow: 0 0 8px 0 #5931f81a;
    background: #fff;
    padding: 16px;
    height: 56px;
    row-gap: 10px;
    transition: box-shadow 0.3s ease, border 0.3s ease;
    border: 2px solid transparent;
}

body[data-theme-style="dark"] .password-box {
    background: #0f172a;
    box-shadow: 0 0 8px 0 #3d5a8033;
}

.password-box:hover {
    border: 2px solid #9b6dd4;
    box-shadow: 0 0 12px 0 #9b6dd4;
}

body[data-theme-style="dark"] .password-box:hover {
    border: 2px solid #5BA3FF;
    box-shadow: 0 0 12px 0 #5BA3FF;
}

.password-box:focus-within {
    border: 2px solid #3883f4;
    box-shadow: 0 0 16px 0 #3883f4;
}

body[data-theme-style="dark"] .password-box:focus-within {
    border: 2px solid #5BA3FF;
    box-shadow: 0 0 16px 0 #5BA3FF;
}

.password-box .form-control {
    border: none;
    box-shadow: none;
    padding: 0;
    height: auto;
    font-size: 20px;
    color: #404040;
    flex: 1;
    width: 100%;
}

body[data-theme-style="dark"] .password-box .form-control {
    background: #0f172a;
    color: #FFFFFF;
}

.password-box .form-control:focus {
    outline: none;
    box-shadow: none;
}

/* ============================================
   Login Options
   ============================================ */

.login-options {
    display: flex;
    align-items: center;
    align-self: stretch;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
}

.option-text {
    line-height: 26px;
    letter-spacing: 0;
    color: #737789;
    font-family: Tajawal, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", SimHei, Arial, Helvetica, sans-serif;
    font-size: 16px;
    font-weight: 500;
}

body[data-theme-style="dark"] .option-text {
    color: #A0A0A0;
}

.options-left {
    display: inline-flex;
    align-items: center;
    column-gap: 8px;
}

/* ============================================
   Submit Button
   ============================================ */

.submit-bar {
    display: flex;
    align-items: center;
    align-self: stretch;
    justify-content: center;
    column-gap: 10px;
    border-radius: 10px;
    padding: 16px;
    height: 56px;
    overflow: hidden;
    background-image: linear-gradient(260.78deg, #6007d4cc -4.91%, #3883f4 90.16%);
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.submit-bar:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px 0 #5931f833;
}

.submit-bar:active {
    transform: translateY(0);
}

.submit-bar .login-btn {
    background: transparent;
    border: none;
    box-shadow: none;
    color: #fff;
    font-size: 24px;
    font-weight: 500;
    padding: 0;
    cursor: pointer;
    width: 100%;
    transition: opacity 0.2s ease;
    -webkit-tap-highlight-color: transparent;
    outline: none;
}

.submit-bar .login-btn:active {
    opacity: 0.5;
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

.submit-bar .login-btn:focus {
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

.submit-bar .login-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

/* ============================================
   Footer
   ============================================ */

.footer-hint {
    display: inline-flex;
    align-items: center;
    align-self: stretch;
    column-gap: 8px;
    margin-right: 157px;
    margin-left: 157px;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-link-text {
    line-height: 26px;
    letter-spacing: 0;
    color: #404040;
    font-family: Tajawal, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", SimHei, Arial, Helvetica, sans-serif;
    font-size: 24px;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.3s ease;
}

body[data-theme-style="dark"] .footer-link-text {
    color: #A0A0A0;
}

.footer-link-text:hover {
    color: #3883f4;
    text-decoration: underline;
}

body[data-theme-style="dark"] .footer-link-text:hover {
    color: #5BA3FF;
}

.footer-link-icon {
    width: 16px;
    height: 16px;
}

body[data-theme-style="dark"] .footer-link-icon {
    filter: brightness(0.8);
}

.footer-link-icon-svg path {
    fill: #404040;
    transition: fill 0.3s ease;
}

body[data-theme-style="dark"] .footer-link-icon-svg path {
    fill: #FFFFFF;
}

/* ============================================
   Responsive Design - Tablets (768px and below)
   ============================================ */

@media (max-width: 768px) {

    .modern-login-container {
        padding: 1.5rem 1rem;
    }

    .login-wrapper {
        width: 100%;
        max-width: 500px;
        row-gap: 30px;
    }

    .login-wrapper .brand-logo {
        width: 100px;
        height: 94px;
        margin-right: 3%;
    }
   html[dir="rtl"] .login-wrapper .brand-logo {
        margin-left: 11%;
    }

    .login-content {
        row-gap: 30px;
    }

    .login-header {
        row-gap: 24px;
        margin: 0;
    }

    .login-title {
        font-size: 27px;
        line-height: 8px;
        margin-top: 10%;
    }

    .signup-subtext {
        font-size: 18px;
        line-height: 22px;
    }

    .signup-hint {
        font-size: 18px;
        line-height: 22px;
    }

    .signup-link {
        font-size: 18px;
        line-height: 22px;
    }

    .login-card {
        padding: 34px;
        width: 140%;
        margin-left: -16%;
        row-gap: 30px;
        border-radius: 12px;
    }
    html[dir="rtl"]  .login-card {
        margin-right: -35%;
        width: 162%;
    }



    .field-label {
        font-size: 18px;
        line-height: 22px;
    }

    .input-group {
        row-gap: 12px;
    }

    .input-box {
        padding: 12px;
        height: 48px;
        border-radius: 8px;
    }

    .input-box .form-control {
        font-size: 16px;
    }

    .password-section {
        row-gap: 12px;
    }

    .password-group {
        row-gap: 12px;
    }

    .password-toggle-icon {
        width: 20px;
        height: 20px;
    }

    .password-box {
        padding: 12px;
        height: 48px;
        border-radius: 8px;
    }

    .password-box .form-control {
        font-size: 16px;
    }

    .option-text {
        font-size: 14px;
        line-height: 20px;
    }

    .submit-bar {
        padding: 12px;
        height: 48px;
        border-radius: 8px;
    }

    .submit-bar .login-btn {
        font-size: 18px;
    }

    .footer-hint {
        margin-right: 0;
        margin-left: 0;
        padding: 0 1rem;
    }

    .footer-link-text {
        font-size: 14px;
        line-height: 20px;
    }

    .footer-link-icon {
        width: 14px;
        height: 14px;
    }
}

/* ============================================
   Responsive Design - Mobile (480px and below)
   ============================================ */

@media (max-width: 480px) {
    .modern-login-container {
        padding: 1rem;
        min-height: auto;
    }

    .login-wrapper {
        width: 100%;
        max-width: 100%;
        row-gap: 20px;
    }

    .login-wrapper .brand-logo {
        width: 80px;
        height: 75px;
        margin-right: 12%;
    }
    html[dir="rtl"] .login-wrapper .brand-logo {
        margin-left: 32%;
    }


    .login-content {
        row-gap: 20px;
    }

    .login-header {
        row-gap: 0px;
        margin: 0;
    }

    .login-title {
        font-size: 22px;
        line-height: 9px;
        margin-top: 19%;
    }

    .signup-subtext {
        font-size: 16px;
        line-height: 20px;
    }

    .signup-hint {
        font-size: 14px;
        line-height: 18px;
    }

    .signup-link {
        font-size: 14px;
        line-height: 18px;
    }

    .login-card {
        padding: 12px;
        row-gap: 20px;
        border-radius: 10px;
    }
     html[dir="rtl"]  .login-card {
        margin-right: -32%;
        width: 162%;
    }


    .field-label {
        font-size: 16px;
        line-height: 20px;
    }

    .input-group {
        row-gap: 10px;
    }

    .input-box {
        padding: 10px;
        height: 44px;
        border-radius: 6px;
    }

    .input-box .form-control {
        font-size: 14px;
    }

    .password-section {
        row-gap: 10px;
    }

    .password-group {
        row-gap: 10px;
    }

    .password-toggle-icon {
        width: 18px;
        height: 18px;
    }

    .password-box {
        padding: 10px;
        height: 44px;
        border-radius: 6px;
    }

    .password-box .form-control {
        font-size: 14px;
    }

    .login-options {
        gap: 8px;
    }

    .option-text {
        font-size: 12px;
        line-height: 16px;
    }

    .submit-bar {
        padding: 10px;
        height: 44px;
        border-radius: 6px;
    }

    .submit-bar .login-btn {
        font-size: 16px;
    }

    .footer-hint {
        margin: 0;
        padding: 0 0.5rem;
        column-gap: 4px;
    }

    .footer-link-text {
        font-size: 12px;
        line-height: 16px;
    }

    .footer-link-icon {
        width: 12px;
        height: 12px;
    }
}

/* ============================================
   Responsive Design - Extra Small (320px and below)
   ============================================ */

@media (max-width: 320px) {
    .modern-login-container {
        padding: 0.75rem;
    }

    .login-wrapper {
        row-gap: 16px;
    }

    .login-wrapper .brand-logo {
        width: 60px;
        height: 45px;
        margin-right: 25%;
        margin-left: 0;
    }

    html[dir="rtl"] .login-wrapper .brand-logo {
        margin-right: 0;
        margin-left: 31%;
    }

    .login-content {
        row-gap: 16px;
    }

    .login-header {
        row-gap: 12px;
        margin: 0;
    }

    .login-title {
        font-size: 20px;
        line-height: 2px;
        margin-top: 36%;
    }

    .signup-subtext {
        font-size: 14px;
        line-height: 18px;
    }

    .signup-hint {
        font-size: 12px;
        line-height: 16px;
    }

    .signup-link {
        font-size: 12px;
        line-height: 16px;
    }

    .login-card {
        padding: 10px;
        row-gap: 16px;
        width: 135%;
        margin-right: -18%;
        margin-left: -16%;
    }

    html[dir="rtl"] .login-card {
        margin-left: 0;
        margin-right: -27%;
        width: 150%;
    }

    .field-label {
        font-size: 14px;
        line-height: 18px;
    }

    .input-box {
        padding: 8px;
        height: 40px;
    }

    .input-box .form-control {
        font-size: 12px;
    }

    .password-box {
        padding: 8px;
        height: 40px;
    }

    .password-box .form-control {
        font-size: 12px;
    }

    .submit-bar {
        padding: 8px;
        height: 40px;
    }

    .submit-bar .login-btn {
        font-size: 14px;
    }

    .footer-link-text {
        font-size: 11px;
        line-height: 14px;
    }
}
