        /* Base styles for body to ensure no horizontal scroll and consistent background */
body {
    overflow-x: hidden;
}

/* Custom styles for the segmented control for better responsiveness */
.segmented-control button {
    white-space: nowrap;
}

/* Style for the toggle switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    margin: 0 8px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .toggle-slider {
    background-color: #10B981;
}

input:focus + .toggle-slider {
    box-shadow: 0 0 1px #10B981;
}

input:checked + .toggle-slider:before {
    transform: translateX(20px);
}

/* Font Faces - sans */
@font-face {
    font-family: 'nmaPersianFont';
    src: url('/fonts/Iran.Sans.Light.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}
/* Font Faces - mono */
@font-face {
    font-family: 'nmaPasswordDisplayFont';
    src: url('/fonts/SourceCodePro.Light.ttf') format('truetype'),
    url('/fonts/IBMPlexMono.Light.ttf') format('truetype'),
         url('/fonts/FiraCode.Light.woff2') format('woff2'),
         url('/fonts/FiraCode.Light.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* Animations */
@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fade-in 0.5s ease-out forwards;
}

@keyframes bounce-lock {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

.animate-bounce-lock {
    animation: bounce-lock 2s infinite;
}

@keyframes pulse-glow {
    0% {
        box-shadow: 0 0 0px 0px rgba(100, 116, 139, 0.7);
    }
    70% {
        box-shadow: 0 0 0px 10px rgba(100, 116, 139, 0);
    }
    100% {
        box-shadow: 0 0 0px 0px rgba(100, 116, 139, 0);
    }
}

.animate-pulse-glow {
    animation: pulse-glow 2s infinite;
}

@keyframes pulse-slow {
    0%, 100% {
        transform: scale(1);
        opacity: 0.1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.05;
    }
}

.animate-pulse-slow {
    animation: pulse-slow 6s infinite ease-in-out;
}

/* Hide scrollbar but keep scrollability */
.hide-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.hide-scrollbar::-webkit-scrollbar {
    display: none;
}

/* Background pattern */
.bg-pattern-fixed {
    background-size: 1000px 1000px;
    background-repeat: repeat;
    background-attachment: fixed;
    background-image: url("./assets/chat_background.svg"); /* مسیر SVG شما */
}

html.dark .bg-pattern-fixed {
    background-image: url("./assets/chat_background.svg"); /* مسیر SVG تیره */
}
@keyframes fade-in-up {
    0% {
        opacity: 0;
        transform: translateY(50px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}
.animate-fade-in-up {
    animation: fade-in-up 0.7s ease-out forwards;
}
    /* Custom Slider Styles */
    .custom-slider {
        -webkit-appearance: none;
        appearance: none;
        width: 100%;
        height: 6px;
        background: #e2e8f0; /* slate-200 */
        border-radius: 9999px;
        outline: none;
        opacity: 0.9;
        transition: opacity 0.2s;
    }

    .dark .custom-slider {
        background: #475569; /* slate-600 */
    }

    .custom-slider:hover {
        opacity: 1;
    }

    /* Thumb (the handle) for Webkit browsers (Chrome, Safari) */
    .custom-slider::-webkit-slider-thumb {
        -webkit-appearance: none;
        appearance: none;
        width: 20px;
        height: 20px;
        background: #10b981; /* emerald-600 */
        cursor: pointer;
        border-radius: 9999px;
        border: 3px solid white;
        box-shadow: 0 0 5px rgba(0,0,0,0.2);
    }
    
    .dark .custom-slider::-webkit-slider-thumb {
        border-color: #334155; /* slate-700 */
    }

    /* Thumb for Firefox */
    .custom-slider::-moz-range-thumb {
        width: 20px;
        height: 20px;
        background: #10b981; /* emerald-600 */
        cursor: pointer;
        border-radius: 9999px;
        border: 3px solid white;
        box-shadow: 0 0 5px rgba(0,0,0,0.2);
    }

    .dark .custom-slider::-moz-range-thumb {
        border-color: #334155; /* slate-700 */
    }
    /* Animated background for motion area */
    @keyframes bg-pan {
      0% { background-position: 0% 0%; }
      100% { background-position: 20px 20px; }
    }
    .motion-area-bg {
        background-image:
            linear-gradient(rgba(148, 163, 184, 0.2) 1px, transparent 1px),
            linear-gradient(90deg, rgba(148, 163, 184, 0.2) 1px, transparent 1px);
        background-size: 20px 20px;
        animation: bg-pan 15s linear infinite;
    }
    .dark .motion-area-bg {
        background-image:
            linear-gradient(rgba(51, 65, 85, 0.7) 1px, transparent 1px),
            linear-gradient(90deg, rgba(51, 65, 85, 0.7) 1px, transparent 1px);
    }
    /* Keyframes for fade-in-up animation */
    @keyframes fade-in-up {
        from {
            opacity: 0;
            transform: translateY(20px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
    .animate-fade-in-up {
        animation: fade-in-up 0.5s ease-out forwards;
    }