/* Dark Mode Authentication Pages with Golden Primary Color */

:root {
    /* Golden primary color variants */
    --bs-primary: #F2B90F;
    --bs-primary-rgb: 242, 185, 15;
    --bs-primary-text-emphasis: #976f06;
    --bs-primary-bg-subtle: #fcf4d6;
    --bs-primary-border-subtle: #f9e6a8;
    --bs-success: #F2B90F;
    --bs-success-rgb: 242, 185, 15;

    /* Dark theme colors */
    --bs-dark: #1a1d21;
    --bs-dark-rgb: 26, 29, 33;
    --bs-body-bg: #0f1419;
    --bs-body-color: #e9ecef;
    --bs-card-bg: #1e2327;
    --bs-border-color: #343a40;
    --bs-form-control-bg: #2c3237;
    --bs-form-control-color: #e9ecef;
    --bs-form-control-border: #495057;
    --bs-muted: #6c757d;
    --bs-light: #343a40;
}

/* Force dark theme on html element */
html {
    background-color: #0f1419 !important;
}

/* Body dark theme */
body {
    background-color: #0f1419 !important;
    color: #e9ecef !important;
}

/* Auth page wrapper */
.auth-page-wrapper {
    background: url(../images/gredientBackground.png);
    background-size: cover;
    color: #e9ecef !important;
    min-height: 100vh;
}

/* Auth background overlay */
.auth-one-bg {
    background: linear-gradient(135deg, #1a1d21 0%, #0f1419 100%) !important;
}

.auth-one-bg .bg-overlay {
    background: rgba(15, 20, 25, 0.85) !important;
}

/* Shape SVG dark theme */
.shape svg path {
    fill: #1a1d21 !important;
}

/* Logo and text adjustments */
.text-white-50 {
    color: #adb5bd !important;
}

/* Card styling */
.card {
    background-color: #fffdfd0d !important;
    color: #e9ecef !important;
    border-radius: 15px;
}

/* Form controls */
.form-control {
    background-color: #d9d9d92b !important;
    border: 1px solid #495057 !important;
    color: #e9ecef !important;
}

.form-control:focus {
    background-color: #2c3237 !important;
    border-color: #b8b8b8 !important;
    box-shadow: 0 0 0 0.25rem rgba(228, 228, 228, 0.25) !important;
    color: #e9ecef !important;
}

.form-control::placeholder {
    color: #a5a5a5 !important;
}

/* Form labels */
.form-label {
    color: #adb5bd !important;
}


/* Text colors */
.text-primary {
    color: #ffffff !important;
}

.text-muted {
    color: #c0c0c0 !important;
}

.text-danger {
    color: #dc3545 !important;
}

/* Primary button styling */
.btn-primary,
.btn-success {
    background-color: #ffffff !important;
    border-color: #e1e1e1 !important;
    color: #1a1d21 !important;
    font-weight: 600;
}

.btn-primary:hover,
.btn-success:hover {
    background-color: #d6d6d6 !important;
    border-color: #bdbdbd !important;
    color: #1a1d21 !important;
}

.btn-primary:focus,
.btn-success:focus {
    background-color: #e3e3e3 !important;
    border-color: #cfcfcf !important;
    box-shadow: 0 0 0 0.25rem rgba(242, 185, 15, 0.25) !important;
    color: #1a1d21 !important;
}

.btn-primary:active,
.btn-success:active {
    background-color: #e0e0e0 !important;
    border-color: #cacaca !important;
    color: #1a1d21 !important;
}

/* Link styling */
.text-decoration-underline {
    color: #ffffff !important;
}

.text-decoration-underline:hover {
    color: #cccccc !important;
}

/* Password toggle button */
.password-addon {
    background: transparent !important;
    border: none !important;
    color: #6c757d !important;
}

.password-addon:hover {
    color: #adb5bd !important;
}

/* Checkbox styling */
.form-check-input {
    background-color: #2c3237 !important;
    border: 1px solid #495057 !important;
}

.form-check-input:checked {
    background-color: #ffffff !important;
    border-color: #dddddd !important;
}

.form-check-input:focus {
    border-color: #ffffff !important;
    box-shadow: 0 0 0 0.25rem rgba(242, 185, 15, 0.25) !important;
}

.form-check-label {
    color: #adb5bd !important;
}

/* Alert styling */
.alert {
    border: 1px solid transparent;
    border-radius: 0.375rem;
}

.alert-success {
    background-color: #d7d7d71a !important;
    border-color: #dfdfdf4d !important;
    color: #ffffff !important;
}

.alert-danger {
    background-color: rgba(220, 53, 69, 0.1) !important;
    border-color: rgba(220, 53, 69, 0.3) !important;
    color: #dc3545 !important;
}

.alert-info {
    background-color: rgba(13, 202, 240, 0.1) !important;
    border-color: rgba(13, 202, 240, 0.3) !important;
    color: #0dcaf0 !important;
}

/* Close button for alerts */
.btn-close {
    filter: invert(1) grayscale(100%) brightness(200%);
}

/* Footer styling */
.footer {
    background-color: transparent !important;
}

.footer .text-muted {
    color: #6c757d !important;
}

/* Country selector dark mode */
.desoft-dropdown {
    background-color: #1e2327 !important;
    border: 1px solid #495057 !important;
    color: #e9ecef !important;
}

.desoft-dropdown-item {
    color: #e9ecef !important;
    border-bottom: 1px solid #343a40 !important;
}

.desoft-dropdown-item:hover,
.desoft-dropdown-item.focused {
    background-color: #343a40 !important;
}

.desoft-dropdown-item:active {
    background-color: #495057 !important;
}

.desoft-no-results {
    color: #6c757d !important;
}

.desoft-dropdown::-webkit-scrollbar-track {
    background: #2c3237 !important;
}

.desoft-dropdown::-webkit-scrollbar-thumb {
    background: #495057 !important;
}

.desoft-dropdown::-webkit-scrollbar-thumb:hover {
    background: #6c757d !important;
}

/* Country flag border */
.desoft-country-flag {
    border: 1px solid #495057 !important;
}

/* Clear button styling */
.btn-outline-secondary {
    background-color: transparent !important;
    border-color: #6c757d !important;
    color: #6c757d !important;
}

.btn-outline-secondary:hover {
    background-color: #6c757d !important;
    border-color: #6c757d !important;
    color: #e9ecef !important;
}

/* Badge styling */
.badge.bg-primary {
    background-color: #ffffff !important;
    color: #1a1d21 !important;
}

/* Password requirements box */
#password-contain {
    background-color: #2c3237 !important;
    border: 1px solid #495057 !important;
    color: #adb5bd !important;
}

/* Invalid feedback */
.invalid-feedback {
    color: #dc3545 !important;
}

/* Required field asterisk */
.text-danger {
    color: #dc3545 !important;
}

/* Spinner for loading states */
.spinner-border {
    color: #1a1d21 !important;
}

/* Focus states for accessibility */
.form-control:focus,
.btn:focus {
    outline: 2px solid #ffffff;
    outline-offset: 2px;
}

/* Animation for smooth transitions */
.card,
.form-control,
.btn {
    transition: all 0.2s ease-in-out;
}

/* Responsive adjustments */
@media (max-width: 576px) {
    .card {
        margin: 1rem;
    }

    .card-body {
        padding: 1.5rem !important;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .form-control {
        border-width: 2px;
    }

    .btn {
        border-width: 2px;
    }
}

/* OTP Verification Modal */
#otpVerificationModal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 1050 !important;
    overflow: hidden;
    display: none;
}

#otpVerificationModal.show {
    display: block !important;
}

/* Custom backdrop contained within modal */
.otp-modal-backdrop {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background-color: rgba(0, 0, 0, 0.8) !important;
    z-index: 1 !important;
    opacity: 0;
    transition: opacity 0.15s linear;
    cursor: not-allowed;
}

.otp-modal-backdrop.show {
    opacity: 1 !important;
}

/* Modal dialog positioned above backdrop */
#otpVerificationModal .modal-dialog {
    position: relative !important;
    z-index: 2 !important;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    /* margin: 0; */
    padding: 1rem;
    margin: 0 auto;
}

#otpVerificationModal .modal-content {
    background-color: #1e2327 !important;
    border: 1px solid #343a40 !important;
    color: #e9ecef !important;
    position: relative !important;
    z-index: 3 !important;
    max-width: 500px;
    width: 100%;
    transform: scale(0.8);
    transition: transform 0.15s ease-out;
}

#otpVerificationModal.show .modal-content {
    transform: scale(1);
}

/* Hide Bootstrap's modal backdrop */
.modal-backdrop {
    display: none !important;
}

.modal-header {
    border-bottom: 1px solid #343a40 !important;
}

.modal-header .btn-close {
    filter: invert(1) grayscale(100%) brightness(200%);
}

.otp-input {
    background-color: #2c3237 !important;
    border: 2px solid #495057 !important;
    color: #e9ecef !important;
    font-weight: 600;
    font-size: 1.25rem;
    padding: 0;
}

.otp-input:focus {
    background-color: #2c3237 !important;
    border-color: #ffffff !important;
    box-shadow: 0 0 0 0.25rem rgba(242, 185, 15, 0.25) !important;
    color: #e9ecef !important;
}

.avatar-title.bg-primary {
    background-color: #ffffff !important;
    color: #1a1d21 !important;
}

/* SweetAlert Dark Mode */
.swal-dark-mode {
    background-color: #1e2327 !important;
}

.swal2-popup {
    background-color: #1e2327 !important;
    color: #e9ecef !important;
}

.swal2-title {
    color: #e9ecef !important;
}

.swal2-content {
    color: #adb5bd !important;
}

.swal2-confirm {
    background-color: #dadada !important;
    border-color: #F2B90F !important;
    color: #1a1d21 !important;
}

.swal2-confirm:hover {
    background-color: #ffffff !important;
    border-color: #dcdcdc !important;
}

/* Resend link states */
#resendOtpLink {
    transition: all 0.2s ease-in-out;
    cursor: pointer;
}

#resendOtpLink:hover:not(.text-muted) {
    color: #dedede !important;
}

#resendOtpLink.text-muted {
    cursor: not-allowed !important;
}

/* Loading spinner animation */
.ri-loader-4-line {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {

    .card,
    .form-control,
    .btn {
        transition: none;
    }

    .ri-loader-4-line {
        animation: none;
    }
}