/* ==========================================================================
   Premium Authentication Unified Stylesheet
   Project: Just Udhari (Jewellery Business Management)
   Styles Shared Across: Login, Register, Forgot Password, Reset Password, OTP Verification
   ========================================================================== */

/* Premium Main Wrapper Area */
.user-area {
    background: radial-gradient(circle at 50% 50%, #faf8f5 0%, #f0e6da 100%) !important;
    position: relative;
    overflow: hidden;
    z-index: 1;
    padding-top: 40px !important;
    padding-bottom: 50px !important;
}

/* Ambient Glow Blobs */
.user-area::before,
.user-area::after {
    content: '';
    position: absolute;
    width: 350px;
    height: 350px;
    border-radius: 50%;
    pointer-events: none;
    z-index: -1;
    filter: blur(80px);
    opacity: 0.4;
}

.user-area::before {
    background: radial-gradient(circle, rgba(238, 93, 25, 0.15) 0%, rgba(0, 0, 0, 0) 70%);
    top: -50px;
    left: -50px;
    animation: floatGlowOne 12s infinite alternate ease-in-out;
}

.user-area::after {
    background: radial-gradient(circle, rgba(212, 175, 55, 0.1) 0%, rgba(0, 0, 0, 0) 70%);
    bottom: -50px;
    right: -50px;
    animation: floatGlowTwo 15s infinite alternate ease-in-out;
}

@keyframes floatGlowOne {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(40px, 40px) scale(1.1); }
}

@keyframes floatGlowTwo {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(-50px, -30px) scale(1.15); }
}

/* Column Container Tweaks */
.user-area .row {
    position: relative;
    z-index: 2;
}

/* Premium Left Column Illustration Card */
.user-img-card {
    background: #ffffff !important;
    border-radius: 30px !important;
    padding: 35px !important;
    position: relative;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(238, 93, 25, 0.05) !important;
    border: 1.5px solid rgba(255, 255, 255, 0.9) !important;
    height: 100%;
    min-height: 560px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    z-index: 1;
    transition: transform 0.4s ease;
}

.user-img-card:hover {
    transform: translateY(-5px);
}

/* Organic decorative card blob */
.left-card-blob {
    position: absolute;
    bottom: -50px;
    left: -50px;
    width: 180px;
    height: 180px;
    background: linear-gradient(135deg, rgba(238, 93, 25, 0.08) 0%, rgba(255, 159, 67, 0.12) 100%);
    border-radius: 50% 30% 80% 20% / 50% 60% 40% 70%;
    z-index: 1;
    pointer-events: none;
    filter: blur(5px);
}

/* Elegant decorative dots pattern */
.left-card-dots {
    position: absolute;
    width: 45px;
    height: 45px;
    background-image: radial-gradient(rgba(238, 93, 25, 0.15) 2px, transparent 2px);
    background-size: 8px 8px;
    z-index: 2;
    pointer-events: none;
}
.left-card-dots.top-left {
    top: 25px;
    left: 25px;
}
.left-card-dots.bottom-right {
    bottom: 25px;
    right: 25px;
}

/* Glassmorphism Right Card Container */
.user-form {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(25px) !important;
    -webkit-backdrop-filter: blur(25px) !important;
    border: 1px solid rgba(0, 0, 0, 0.05) !important;
    border-radius: 30px !important;
    padding: 65px 30px 30px 30px !important;
    box-shadow: 0 25px 50px -12px rgba(238, 93, 25, 0.04) !important;
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    min-height: 560px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Curved Header Wave for Right Card */
.user-form-header-wave {
    position: absolute;
    top: 0;
    right: 0;
    width: 180px;
    height: 110px;
    pointer-events: none;
    z-index: 5;
    overflow: hidden;
}

.user-form-header-wave svg.wave-svg {
    width: 100%;
    height: 100%;
}

/* Animated Accent Shield Container */
.accent-shield-container {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 38px;
    height: 38px;
    z-index: 6;
    animation: floatShield 4s infinite ease-in-out;
}

.accent-shield-container svg.shield-svg {
    width: 100%;
    height: 100%;
}

@keyframes floatShield {
    0%, 100% {
        transform: scale(1) translateY(0);
        filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.15));
    }
    50% {
        transform: scale(1.06) translateY(-2px);
        filter: drop-shadow(0 6px 12px rgba(238, 93, 25, 0.35));
    }
}

/* Sleek Modern Input Form Fields */
.user-form .form-group {
    margin-bottom: 12px !important;
    position: relative;
}

.user-form .form-control {
    background: #fbfbfc !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    border-radius: 12px !important;
    height: 48px !important;
    padding: 0 20px 0 45px !important;
    color: #1e293b !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    box-shadow: none !important;
}

.user-form .form-control::placeholder {
    color: #94a3b8 !important;
    font-weight: 400 !important;
}

.user-form .form-control:focus {
    border-color: #ee5d19 !important;
    background: #ffffff !important;
    box-shadow: 0 0 15px rgba(238, 93, 25, 0.08) !important;
    outline: none !important;
}

/* Custom native select arrow styling for register form */
.user-form select.form-control {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='rgba(0,0,0,0.4)' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 18px center !important;
    background-size: 14px !important;
    padding-right: 35px !important;
}

.user-form select.form-control option {
    background-color: #ffffff !important;
    color: #1e293b !important;
    padding: 10px !important;
}

/* Icon Overlays inside input fields */
.user-form .form-group::before {
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    left: 16px;
    top: 24px; /* Fixed vertical center for 48px high inputs */
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 14px;
    transition: color 0.3s ease;
    z-index: 10;
    pointer-events: none;
}

.user-form .form-group.user-input-group::before {
    content: '\f007'; /* User Icon */
}

.user-form .form-group.pass-input-group::before {
    content: '\f023'; /* Lock Icon */
}

.user-form .form-group.phone-input-group::before {
    content: '\f095'; /* Phone Icon */
}

.user-form .form-group.otp-input-group::before {
    content: '\f084'; /* Key/Lock Icon */
}

.user-form .form-group.mpin-input-group::before {
    content: '\f3ed'; /* Shield Icon */
}

.user-form .form-group.shop-input-group::before {
    content: '\f54e'; /* Store Icon */
}

.user-form .form-group.map-input-group::before {
    content: '\f3c5'; /* Map Marker Icon */
}

.user-form .form-group.state-input-group::before {
    content: '\f0ac'; /* Globe Icon */
}

.user-form .form-group.district-input-group::before {
    content: '\f1ad'; /* Building Icon */
}

.user-form .form-group.email-input-group::before {
    content: '\f0e0'; /* Envelope Icon */
}

.user-form .form-group:focus-within::before {
    color: #ee5d19;
}

/* Password Toggle Eyes */
.password-toggle-icon {
    position: absolute !important;
    right: 18px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    cursor: pointer !important;
    color: #94a3b8 !important;
    z-index: 20 !important;
    transition: color 0.3s ease !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
}

.password-toggle-icon:hover {
    color: #ee5d19 !important;
}

/* Change eye icon color to dark charcoal when browser autofills with white/light backgrounds */
.user-form .form-control:-webkit-autofill ~ .password-toggle-icon {
    color: #1e293b !important;
}

/* Checkbox & Remember Me styling */
.agree-label {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    margin-bottom: 12px !important;
    color: #475569 !important;
    font-size: 13px !important;
}

.agree-label label {
    color: #475569 !important;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    user-select: none;
    margin: 0 !important;
}

/* Styling Custom Checkbox matching Mockup precisely */
.agree-label input[type="checkbox"] {
    accent-color: #ee5d19 !important;
    width: 16px !important;
    height: 16px !important;
    border-radius: 4px !important;
    cursor: pointer;
}

/* Forget Password Link */
.agree-label .forget {
    color: #ee5d19 !important;
    font-weight: 600 !important;
    text-decoration: none !important;
    transition: opacity 0.2s ease !important;
}

.agree-label .forget:hover {
    opacity: 0.8;
}

/* Premium Gradient Button CTA styling */
.user-form .default-btn,
.user-form .submit-btn {
    width: fit-content !important;
    padding: 0 45px !important;
    margin: 0 auto !important;
    height: 48px !important;
    background: linear-gradient(135deg, #ee5d19 0%, #ff9f43 100%) !important;
    border: none !important;
    color: #ffffff !important;
    font-family: 'Outfit', sans-serif !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    letter-spacing: 0.5px !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    cursor: pointer !important;
    box-shadow: 0 8px 25px rgba(238, 93, 25, 0.2) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
}

.user-form .default-btn:hover,
.user-form .submit-btn:hover {
    box-shadow: 0 12px 30px rgba(238, 93, 25, 0.35) !important;
    transform: translateY(-1px) !important;
    color: #ffffff !important;
}

.user-form .default-btn:active,
.user-form .submit-btn:active {
    transform: translateY(1px) !important;
}

/* Elegant Login Divider */
.login-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 12px 0 8px 0;
    color: #64748b;
    font-size: 12px;
    font-weight: 500;
}

.login-divider::before,
.login-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.login-divider:not(:empty)::before {
    margin-right: .75em;
}

.login-divider:not(:empty)::after {
    margin-left: .75em;
}

/* Luxury Google Sign In Button */
.google-login-btn {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px;
    width: 100% !important;
    height: 48px !important;
    background: #ffffff !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    border-radius: 12px !important;
    color: #475569 !important;
    font-family: 'Outfit', sans-serif !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    text-decoration: none !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    cursor: pointer !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.01) !important;
}

.google-login-btn:hover {
    background: #f8fafc !important;
    border-color: rgba(0, 0, 0, 0.12) !important;
    transform: translateY(-1px) !important;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.04) !important;
    color: #475569 !important;
}

/* Account Descriptions & Links */
.account-desc {
    text-align: center !important;
    margin-top: 15px !important;
    color: #64748b !important;
    font-size: 13px !important;
    margin-bottom: 0 !important;
}

.account-desc a {
    color: #ee5d19 !important;
    font-weight: 600 !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
    margin-left: 4px;
}

.account-desc a:hover {
    opacity: 0.8;
}

/* Custom OTP boxes & countdown elements */
.otp_box {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    margin-top: 8px !important;
    width: 100% !important;
}

#countdown {
    font-size: 13px !important;
    font-weight: 600 !important;
    color: #ee5d19 !important;
    display: flex;
    align-items: center;
    gap: 4px;
}

.otp_btn {
    background: transparent !important;
    border: none !important;
    color: #ee5d19 !important;
    font-weight: 700 !important;
    font-size: 13px !important;
    cursor: pointer !important;
    padding: 0 !important;
    transition: opacity 0.2s ease !important;
    text-decoration: underline !important;
}

.otp_btn:hover {
    opacity: 0.8 !important;
}

.otp_btn:disabled {
    opacity: 0.4 !important;
    cursor: not-allowed !important;
}

#otp_timer_li {
    opacity: 0.3;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
}

#otp_timer_li.active {
    opacity: 1;
    color: #ee5d19 !important;
}

#act_response_block a {
    color: #ee5d19 !important;
    font-weight: 600;
    text-decoration: none;
}

#act_response_block a:hover {
    opacity: 0.8;
}

/* Elegant Custom Alert Banners */
.user-form .alert {
    border-radius: 10px !important;
    padding: 12px 15px !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    display: flex;
    align-items: center !important;
    gap: 8px !important;
    border: 1px solid transparent !important;
    margin-top: 12px !important;
    margin-bottom: 0 !important;
}

.user-form .alert-danger {
    background: rgba(235, 77, 75, 0.08) !important;
    border-color: rgba(235, 77, 75, 0.15) !important;
    color: #ff7675 !important;
}

.user-form .alert-success {
    background: rgba(46, 204, 113, 0.08) !important;
    border-color: rgba(46, 204, 113, 0.15) !important;
    color: #2ecc71 !important;
}

.user-form .alert ul {
    margin: 0 !important;
    padding-left: 15px !important;
}

/* 3D Card Flip Perspective Container & Inner Styles */
.flip-card-container {
    perspective: 1500px;
    width: 100%;
    height: 560px;
    position: relative;
}

.flip-card-container.flipped {
    height: 560px;
}

.flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
}

.flip-card-container.flipped .flip-card-inner {
    transform: rotateY(180deg);
}

.flip-card-front, .flip-card-back {
    position: absolute !important;
    width: 100% !important;
    height: 100% !important;
    backface-visibility: hidden !important;
    -webkit-backface-visibility: hidden !important;
    top: 0;
    left: 0;
    border-radius: 30px !important;
    overflow: hidden !important;
    -webkit-mask-image: -webkit-radial-gradient(white, black);
}

.flip-card-front {
    z-index: 2;
    transform: rotateY(0deg);
}

.flip-card-back {
    transform: rotateY(180deg);
    z-index: 1;
}

/* Select2 Custom Skin Overrides */
.select2-container--default .select2-selection--single {
    background: #fbfbfc !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    border-radius: 12px !important;
    height: 48px !important;
    display: flex !important;
    align-items: center !important;
    padding-left: 45px !important;
    color: #1e293b !important;
    box-shadow: none !important;
    transition: all 0.3s ease;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    color: #1e293b !important;
    padding-left: 5px !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 46px !important;
    right: 15px !important;
}

.select2-dropdown {
    background: #ffffff !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    border-radius: 12px !important;
    box-shadow: 0 10px 30px rgba(0,0,0,0.06) !important;
    z-index: 9999;
}

.select2-results__option {
    color: #475569 !important;
    padding: 10px 15px !important;
}

.select2-results__option--highlighted[aria-selected] {
    background-color: #ee5d19 !important;
    color: #ffffff !important;
}

.select2-container--default .select2-search--dropdown .select2-search__field {
    background: #fbfbfc !important;
    border: 1px solid rgba(0,0,0,0.08) !important;
    color: #1e293b !important;
    border-radius: 8px !important;
}

/* Responsive Breakpoints */
@media (max-width: 991px) {
    .user-img-card {
        margin-bottom: 40px !important;
        min-height: 480px;
    }
    .user-form {
        padding: 95px 25px 20px 25px !important;
    }
}
