/* ═══════════════════════════════════════════════════════════ */
/*                                                            */
/*                    کانال‌شاپ - استایل سفارشی              */
/*                                                            */
/*  این فایل فقط استایل‌های مکمل Tailwind را دارد            */
/*  از تنظیم رنگ، پس‌زمینه و فونت پرهیز کنید                 */
/*                                                            */
/* ═══════════════════════════════════════════════════════════ */


/* ═══════════════════════════════════════════════════════════ */
/* 1. LINE CLAMP - کوتاه کردن متن                            */
/* ═══════════════════════════════════════════════════════════ */

.line-clamp-1 {
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.line-clamp-4 {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}


/* ═══════════════════════════════════════════════════════════ */
/* 2. ANIMATIONS - انیمیشن‌ها                                 */
/* ═══════════════════════════════════════════════════════════ */

@keyframes slide-in {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slide-in-right {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes fade-in {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes bounce-in {
    0% {
        transform: scale(0.8);
        opacity: 0;
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes pulse-slow {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

@keyframes spin-slow {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.animate-slide-in {
    animation: slide-in 0.3s ease-out;
}

.animate-slide-in-right {
    animation: slide-in-right 0.3s ease-out;
}

.animate-fade-in {
    animation: fade-in 0.3s ease-out;
}

.animate-bounce-in {
    animation: bounce-in 0.4s ease-out;
}

.animate-pulse-slow {
    animation: pulse-slow 2s ease-in-out infinite;
}

.animate-spin-slow {
    animation: spin-slow 3s linear infinite;
}


/* ═══════════════════════════════════════════════════════════ */
/* 3. SCROLLBAR - نوار پیمایش سفارشی                         */
/* ═══════════════════════════════════════════════════════════ */

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: #fb923c;
    border-radius: 10px;
    transition: background 0.2s;
}

::-webkit-scrollbar-thumb:hover {
    background: #ea580c;
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: #fb923c #f1f1f1;
}


/* ═══════════════════════════════════════════════════════════ */
/* 4. FOCUS & INPUT - حالت فوکوس                              */
/* ═══════════════════════════════════════════════════════════ */

input:focus,
textarea:focus,
select:focus {
    outline: none;
}

input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(251, 146, 60, 0.2);
}

/* حذف فلش‌های input number */
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

input[type="number"] {
    -moz-appearance: textfield;
}

/* Placeholder */
::placeholder {
    color: #9ca3af;
    opacity: 1;
}

:-ms-input-placeholder {
    color: #9ca3af;
}

::-ms-input-placeholder {
    color: #9ca3af;
}


/* ═══════════════════════════════════════════════════════════ */
/* 5. RTL HELPERS - کمک‌های راست‌چین                          */
/* ═══════════════════════════════════════════════════════════ */

[dir="ltr"] {
    direction: ltr;
    text-align: left;
}

.dir-ltr {
    direction: ltr;
}

.dir-rtl {
    direction: rtl;
}


/* ═══════════════════════════════════════════════════════════ */
/* 6. HOVER EFFECTS - افکت‌های هاور                           */
/* ═══════════════════════════════════════════════════════════ */

.hover-lift {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hover-lift:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.hover-scale {
    transition: transform 0.2s ease;
}

.hover-scale:hover {
    transform: scale(1.05);
}

.hover-shadow:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}


/* ═══════════════════════════════════════════════════════════ */
/* 7. TRANSITIONS - انتقال‌ها                                 */
/* ═══════════════════════════════════════════════════════════ */

.transition-all-200 {
    transition: all 0.2s ease;
}

.transition-all-300 {
    transition: all 0.3s ease;
}

.transition-colors {
    transition: color 0.2s, background-color 0.2s, border-color 0.2s;
}


/* ═══════════════════════════════════════════════════════════ */
/* 8. ASPECT RATIO - نسبت ابعاد                              */
/* ═══════════════════════════════════════════════════════════ */

.aspect-video {
    aspect-ratio: 16 / 9;
}

.aspect-square {
    aspect-ratio: 1 / 1;
}


/* ═══════════════════════════════════════════════════════════ */
/* 9. LOADING - نشانگر بارگذاری                              */
/* ═══════════════════════════════════════════════════════════ */

.spinner {
    border: 3px solid rgba(251, 146, 60, 0.2);
    border-top-color: #fb923c;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin-slow 0.8s linear infinite;
}

.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite;
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}


/* ═══════════════════════════════════════════════════════════ */
/* 10. BACKDROP BLUR - پس‌زمینه تار                           */
/* ═══════════════════════════════════════════════════════════ */

.backdrop-blur-sm {
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.backdrop-blur-md {
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}


/* ═══════════════════════════════════════════════════════════ */
/* 11. STICKY HELPERS - کمک‌های چسبندگی                       */
/* ═══════════════════════════════════════════════════════════ */

.sticky-top-header {
    position: sticky;
    top: 72px;
    z-index: 40;
}

.sticky-top-header-full {
    position: sticky;
    top: 96px;
    z-index: 40;
}


/* ═══════════════════════════════════════════════════════════ */
/* 12. BADGE - نشان‌ها                                        */
/* ═══════════════════════════════════════════════════════════ */

.badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    font-size: 11px;
    border-radius: 9999px;
    font-weight: 500;
    line-height: 1.5;
}

.badge-success {
    background: #dcfce7;
    color: #166534;
}

.badge-error {
    background: #fee2e2;
    color: #991b1b;
}

.badge-warning {
    background: #fef3c7;
    color: #92400e;
}

.badge-info {
    background: #dbeafe;
    color: #1e40af;
}

.badge-orange {
    background: #ffedd5;
    color: #9a3412;
}


/* ═══════════════════════════════════════════════════════════ */
/* 13. PRINT - چاپ                                           */
/* ═══════════════════════════════════════════════════════════ */

@media print {
    header,
    footer,
    button,
    .no-print {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .container {
        max-width: 100% !important;
    }
    
    a {
        text-decoration: none;
        color: black;
    }
}


/* ═══════════════════════════════════════════════════════════ */
/* 14. RESPONSIVE FIXES - اصلاحات واکنش‌گرا                   */
/* ═══════════════════════════════════════════════════════════ */

@media (max-width: 640px) {
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

/* جلوگیری از سرریز متن‌های طولانی */
.break-words {
    word-wrap: break-word;
    word-break: break-word;
    overflow-wrap: break-word;
}

/* مخفی کردن عناصر */
.hidden-important {
    display: none !important;
}


/* ═══════════════════════════════════════════════════════════ */
/* 15. UTILITIES - ابزارهای کمکی                              */
/* ═══════════════════════════════════════════════════════════ */

/* جهت‌یابی کامل */
.text-center-full {
    text-align: center;
    width: 100%;
}

/* ارتفاع حداقلی صفحه */
.min-h-screen-safe {
    min-height: calc(100vh - 200px);
}

/* overflow-x برای موبایل */
.overflow-x-safe {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.overflow-x-safe::-webkit-scrollbar {
    height: 4px;
}

.overflow-x-safe::-webkit-scrollbar-thumb {
    background: #fb923c;
    border-radius: 4px;
}


/* ═══════════════════════════════════════════════════════════ */
/* 16. FIX برای خطاهای رایج                                  */
/* ═══════════════════════════════════════════════════════════ */

/* جلوگیری از پرش layout در هنگام باز شدن مودال‌ها */
body.modal-open {
    overflow: hidden;
}

/* حذف تکرار دکوریشن دکمه‌ها */
button {
    cursor: pointer;
}

button:disabled {
    cursor: not-allowed;
}

/* لینک‌ها بدون underline پیش‌فرض */
a {
    text-decoration: none;
}

a:hover {
    text-decoration: none;
}

/* تصاویر بدون درگ */
img {
    user-select: none;
    -webkit-user-drag: none;
}

/* Text selection */
::selection {
    background: #fb923c;
    color: white;
}

::-moz-selection {
    background: #fb923c;
    color: white;
}


/* ═══════════════════════════════════════════════════════════ */
/* نوار پشتیبانی بالایی                                         */
/* ═══════════════════════════════════════════════════════════ */
.support-top-bar {
    background: linear-gradient(135deg, #1a1f2a 0%, #0f1117 100%);
    border-bottom: 1px solid rgba(249, 115, 22, 0.2);
    padding: 12px 0;
    position: relative;
    z-index: 99;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.support-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px 20px;
}

.support-welcome {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.support-welcome .welcome-icon {
    background: rgba(249, 115, 22, 0.12);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #f97316;
    border: 1px solid rgba(249, 115, 22, 0.2);
    animation: pulse-icon 2s infinite;
    flex-shrink: 0;
}

@keyframes pulse-icon {
    0% { box-shadow: 0 0 0 0 rgba(249, 115, 22, 0.3); }
    70% { box-shadow: 0 0 0 8px rgba(249, 115, 22, 0); }
    100% { box-shadow: 0 0 0 0 rgba(249, 115, 22, 0); }
}

.support-welcome .welcome-text {
    font-size: 0.95rem;
    color: #e2e8f0;
    font-weight: 400;
    letter-spacing: 0.3px;
}

.support-welcome .welcome-text strong {
    color: #f97316;
    font-weight: 700;
}

.support-welcome .welcome-text .highlight {
    background: linear-gradient(135deg, #f97316, #ea580c);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: 700;
}

.support-phone {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(249, 115, 22, 0.08);
    padding: 6px 18px 6px 22px;
    border-radius: 60px;
    border: 1px solid rgba(249, 115, 22, 0.2);
    transition: all 0.3s ease;
    text-decoration: none;
}

.support-phone:hover {
    background: rgba(249, 115, 22, 0.15);
    border-color: rgba(249, 115, 22, 0.4);
    transform: translateX(-3px);
}

.support-phone i {
    color: #f97316;
    font-size: 18px;
    animation: ring 2s infinite;
}

@keyframes ring {
    0% { transform: rotate(0); }
    5% { transform: rotate(15deg); }
    10% { transform: rotate(-15deg); }
    15% { transform: rotate(0); }
    100% { transform: rotate(0); }
}

.support-phone .phone-number {
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.support-phone .phone-label {
    color: #9ca3af;
    font-size: 0.75rem;
    font-weight: 300;
    margin-left: 4px;
}

.support-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(34, 197, 94, 0.12);
    padding: 4px 14px;
    border-radius: 40px;
    border: 1px solid rgba(34, 197, 94, 0.2);
}

.support-badge .dot {
    width: 8px;
    height: 8px;
    background: #22c55e;
    border-radius: 50%;
    animation: blink 1.4s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.support-badge span {
    color: #22c55e;
    font-size: 0.7rem;
    font-weight: 600;
}

/* دکمه کانال ایتا */
.support-eitaa {
    display: flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, #1e40af, #3b82f6);
    padding: 6px 18px 6px 14px;
    border-radius: 60px;
    border: 1px solid rgba(59, 130, 246, 0.4);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.25);
}

.support-eitaa::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    animation: eitaaShine 3s infinite;
}

@keyframes eitaaShine {
    0% { left: -100%; }
    50% { left: 100%; }
    100% { left: 100%; }
}

.support-eitaa:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.45);
    border-color: rgba(59, 130, 246, 0.7);
}

.support-eitaa .eitaa-icon {
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: white;
    animation: eitaaPulse 2s infinite;
}

@keyframes eitaaPulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.3); }
    50% { box-shadow: 0 0 0 6px rgba(255, 255, 255, 0); }
}

.support-eitaa .eitaa-text {
    display: flex;
    flex-direction: column;
    line-height: 1.2;
}

.support-eitaa .eitaa-text .eitaa-label {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.65rem;
    font-weight: 400;
}

.support-eitaa .eitaa-text .eitaa-id {
    color: #ffffff;
    font-size: 0.9rem;
    font-weight: 700;
    direction: ltr;
    font-family: 'Courier New', monospace;
    letter-spacing: 0.5px;
}

.support-eitaa .eitaa-arrow {
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    transition: transform 0.2s;
}

.support-eitaa:hover .eitaa-arrow {
    transform: translateX(-4px);
    color: white;
}

/* ریسپانسیو نوار پشتیبانی */
@media (max-width: 768px) {
    .support-content {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }
    .support-welcome {
        justify-content: center;
    }
    .support-welcome .welcome-text {
        font-size: 0.85rem;
    }
    .support-phone {
        justify-content: center;
        padding: 8px 16px;
    }
    .support-phone .phone-number {
        font-size: 0.95rem;
    }
    .support-badge {
        display: none;
    }
    .support-eitaa {
        justify-content: center;
        padding: 8px 16px;
    }
    .support-eitaa .eitaa-text .eitaa-id {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .support-welcome .welcome-icon {
        width: 36px;
        height: 36px;
        font-size: 16px;
    }
    .support-welcome .welcome-text {
        font-size: 0.75rem;
    }
    .support-phone .phone-number {
        font-size: 0.85rem;
    }
    .support-eitaa .eitaa-text .eitaa-label {
        font-size: 0.6rem;
    }
    .support-eitaa .eitaa-text .eitaa-id {
        font-size: 0.75rem;
    }
    .support-eitaa .eitaa-icon {
        width: 24px;
        height: 24px;
        font-size: 12px;
    }
}
/* Modal animation */
@keyframes modal-slide-in {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

#success-modal > div {
    animation: modal-slide-in 0.3s ease-out;
}