/* تنظیمات اصلی صفحه */
html,
body {
    height: 100%;
    margin: 0;
    background-color: #e5e7eb;
    overflow: hidden;
    touch-action: manipulation;
}

#main-scroll-container {
    height: 100vh;
    height: 100dvh;
    overflow-y: scroll;
    scroll-snap-type: y mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.snap-section {
    height: 100vh;
    height: 100dvh;
    width: 100%;
    scroll-snap-align: start;
    scroll-snap-stop: always;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;

    @media (max-width: 768px) {
        padding: 0.5rem;
        padding-top: 4rem;
    }
}

.content-card {
    width: 100%;
    max-width: none;
    height: 85vh;
    height: 85dvh;
    border-radius: 1.5rem;

    @media (max-width: 768px) {
        border-radius: 1rem;
        height: 88dvh;
    }

    position: relative;
    box-shadow: 0 20px 40px -5px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    padding-top: 3rem;

    @media (max-width: 768px) {
        padding-top: 1rem;
    }
}

.card-body {
    flex: 1;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 2rem;

    &::-webkit-scrollbar {
        display: none;
    }

    -ms-overflow-style: none;
    scrollbar-width: none;
}

.scrollbar-hide::-webkit-scrollbar {
    display: none;
}

.scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.scroll-hint {
    position: absolute;
    bottom: 1rem;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(4px);
    border-radius: 50%;
    padding: 0.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    z-index: 20;
    opacity: 0;
    transition: opacity 0.3s ease, visibility 0.3s;
    pointer-events: none;
    visibility: hidden;
}

.scroll-hint.center-hint {
    left: 50%;
    transform: translateX(-50%);
}

.scroll-hint.impl-hint {
    left: 50%;
    transform: translateX(-50%);
}

@media (min-width: 768px) {
    .scroll-hint.impl-hint {
        left: auto;
        right: 25%;
        transform: translateX(50%);
    }
}

.scroll-hint.visible {
    opacity: 1;
    visibility: visible;
    animation: bounce 2s infinite;
}

nav {
    transition: all 0.3s ease;
}

.nav-link.active {
    color: #0284c7;
    font-weight: 800;
    background-color: rgba(255, 255, 255, 0.6);
}

.chat-bubble {
    max-width: 85%;
    padding: 12px 16px;
    border-radius: 18px;
    margin-bottom: 12px;
    position: relative;
    font-size: 0.95rem;
    word-wrap: break-word;
    cursor: default;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.chat-bubble.user {
    background-color: #0284c7;
    color: white;
    align-self: flex-end;
    border-bottom-left-radius: 4px;
}

.chat-bubble.admin {
    background-color: #f3f4f6;
    color: #1f2937;
    align-self: flex-start;
    border-bottom-right-radius: 4px;
    border: 1px solid #e5e7eb;
}

.input-error {
    border-color: #ef4444 !important;
    background-color: #fef2f2;
}

.input-success {
    border-color: #22c55e !important;
    background-color: #f0fdf4;
}

.error-msg {
    color: #ef4444;
    font-size: 0.75rem;
    margin-top: 4px;
    display: none;
}

.error-msg.show {
    display: block;
    animation: fadeIn 0.3s;
}

.ticket-item {
    transition: all 0.2s;
    cursor: pointer;
}

.ticket-item:hover {
    transform: translateX(-5px);
}

.break-text {
    word-break: break-word;
    overflow-wrap: anywhere;
    hyphens: auto;
}

/* Toast Animations */
@keyframes toast-slide-in {
    from {
        transform: translateY(100%) scale(0.9);
        opacity: 0;
    }

    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

@keyframes toast-fade-out {
    from {
        opacity: 1;
        transform: scale(1);
    }

    to {
        opacity: 0;
        transform: scale(0.95);
    }
}

.toast-enter {
    animation: toast-slide-in 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.toast-exit {
    animation: toast-fade-out 0.2s forwards;
}

.background-style {
    background-image: url('https://www.transparenttextures.com/patterns/cubes.png');
    background-repeat: repeat;
    background-size: auto;
    background-position: center;
    filter: brightness(0.4) contrast(2);
}