/* أنماط إضافية لموقع Ownly */

/* تحسينات للعرض على الجوال */
@media (max-width: 768px) {
    html {
        font-size: 14px;
    }
    
    /* تحسين التباين للوضع الليلي */
    .dark body {
        background-color: #0B0F19;
    }
    
    /* تحسين النافذة المنبثقة */
    #privacy-modal .max-w-2xl {
        margin: 1rem;
        width: calc(100% - 2rem);
    }
    
    /* تكبير الشعار على الجوال */
    .logo-container span {
        font-size: 1.5rem;
    }
}

/* تحسينات التمرير */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.dark ::-webkit-scrollbar-track {
    background: #1f2937;
}

::-webkit-scrollbar-thumb {
    background: #FACC15;
    border-radius: 5px;
    transition: all 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: #d97706;
    transform: scale(1.1);
}

.dark ::-webkit-scrollbar-thumb {
    background: #d97706;
}

.dark ::-webkit-scrollbar-thumb:hover {
    background: #facc15;
}

/* تحسينات الصور */
img {
    max-width: 100%;
    height: auto;
    transition: all 0.3s ease;
}

/* تحسينات النصوص العربية */
.font-arabic {
    letter-spacing: 0;
    line-height: 1.8;
}

/* أنيميشن زر الواتساب */
@keyframes pulse-whatsapp {
    0%, 100% { 
        transform: scale(1); 
        box-shadow: 0 10px 25px rgba(37, 211, 102, 0.3);
    }
    50% { 
        transform: scale(1.05); 
        box-shadow: 0 15px 30px rgba(37, 211, 102, 0.5);
    }
}

.whatsapp-btn {
    animation: pulse-whatsapp 2s infinite;
}

.whatsapp-btn:hover {
    animation: none;
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 20px 40px rgba(37, 211, 102, 0.7);
}

/* تحسينات بطاقات المنتجات */
.product-card {
    transition: all 0.3s ease;
    backface-visibility: hidden;
    transform-style: preserve-3d;
}

.product-card:hover {
    transform: translateY(-8px) rotateX(2deg);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.dark .product-card:hover {
    box-shadow: 0 20px 40px rgba(250, 204, 21, 0.1);
}

/* تحسينات النافذة المنبثقة */
#privacy-modal {
    transition: opacity 0.3s ease;
}

#privacy-modal > div {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-content {
    animation: modalAppear 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes modalAppear {
    from {
        opacity: 0;
        transform: scale(0.7) rotateX(-10deg);
    }
    to {
        opacity: 1;
        transform: scale(1) rotateX(0);
    }
}

/* خط مقطوع للنصوص الطويلة */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* تحسينات الوصول (Accessibility) */
:focus {
    outline: 2px solid #FACC15;
    outline-offset: 3px;
    border-radius: 4px;
}

/* تأثيرات تفاعلية إضافية */
.hover-glow {
    transition: all 0.3s ease;
}

.hover-glow:hover {
    text-shadow: 0 0 10px rgba(250, 204, 21, 0.5);
}

.hero-banner:hover {
    transform: translateY(-5px);
}

.category-card:hover .icon-container {
    transform: rotate(15deg) scale(1.1);
}

.feature-card:hover .feature-icon {
    animation: bounce 0.6s ease;
}

.search-input:focus {
    transform: scale(1.02);
}

.search-focused svg {
    transform: scale(1.2) rotate(10deg);
    color: #FACC15;
}

.cta-button:hover {
    animation: none;
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 10px 25px rgba(250, 204, 21, 0.4);
}

/* تأثيرات خاصة للشعار */
.logo-container:hover img {
    animation: logoSpin 0.6s ease;
}

@keyframes logoSpin {
    0% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(10deg) scale(1.1); }
    100% { transform: rotate(0deg) scale(1.1); }
}

/* تأثير توهج للعناصر المهمة */
.hover-glow-effect {
    transition: all 0.3s ease;
}

.hover-glow-effect:hover {
    box-shadow: 0 0 20px rgba(250, 204, 21, 0.3);
}

/* تأثيرات للروابط */
a {
    position: relative;
    transition: all 0.3s ease;
}

a:hover::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: #FACC15;
    transform: scaleX(1);
    transition: transform 0.3s ease;
}

a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: #FACC15;
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

/* تحسينات التحميل */
.loading-spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #FACC15;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* تأثيرات للعناوين */
h1, h2, h3 {
    position: relative;
}

h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    right: 0;
    width: 60px;
    height: 3px;
    background: #FACC15;
    transition: width 0.3s ease;
}

h2:hover::after {
    width: 100px;
}

/* تحسينات للطباعة */
@media print {
    .whatsapp-btn,
    nav,
    footer,
    #privacy-modal {
        display: none !important;
    }
    
    body {
        color: #000 !important;
        background: #fff !important;
    }
    
    .product-card {
        break-inside: avoid;
        border: 1px solid #ddd !important;
    }
}

/* تأثيرات للهواتف */
@media (hover: none) {
    .product-card:hover {
        transform: none;
    }
    
    .category-card:hover {
        transform: none;
    }
    
    .feature-card:hover {
        transform: none;
    }
}

/* تأثيرات خاصة للوضع الليلي */
.dark .product-card:hover {
    border-color: #FACC15;
    box-shadow: 0 10px 30px rgba(250, 204, 21, 0.1);
}

/* تأثيرات للفئات */
.category-card {
    position: relative;
    overflow: hidden;
}

.category-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    transition: left 0.5s ease;
}

.category-card:hover::before {
    left: 100%;
}

/* تأثيرات تفاعلية للبنر */
.hero-banner {
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* أنماط جديدة للأسعار */
.line-through {
    position: relative;
}

.line-through::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 1px;
    background-color: #EF4444;
    transform: rotate(-15deg);
}

/* تأثيرات للخصومات */
@keyframes discountPulse {
    0%, 100% { 
        transform: scale(1); 
        background-color: #EF4444;
    }
    50% { 
        transform: scale(1.05); 
        background-color: #DC2626;
    }
}

.discount-badge {
    animation: discountPulse 2s infinite;
}

/* تحسينات لأسعار البيع */
.sale-price {
    color: #EF4444;
    font-weight: 800;
    text-shadow: 0 2px 4px rgba(239, 68, 68, 0.2);
}

.original-price {
    color: #6B7280;
    position: relative;
}

/* تأثيرات لزر الطلب */
.order-button {
    background: linear-gradient(135deg, #111827 0%, #1F2937 100%);
    transition: all 0.3s ease;
}

.order-button:hover {
    background: linear-gradient(135deg, #FACC15 0%, #EAB308 100%);
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(250, 204, 21, 0.4);
}

.dark .order-button {
    background: linear-gradient(135deg, #FACC15 0%, #EAB308 100%);
    color: #111827;
}

.dark .order-button:hover {
    background: linear-gradient(135deg, #FDE047 0%, #FACC15 100%);
}

/* تأثيرات للبقع الخصم */
.discount-tag {
    position: relative;
    overflow: hidden;
}

.discount-tag::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255,255,255,0.1), transparent);
    transform: rotate(45deg);
    animation: shine 3s infinite;
}

@keyframes shine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

/* أنماط للشحن المجاني */
.free-shipping {
    background: linear-gradient(135deg, #10B981 0%, #059669 100%);
    animation: freeShippingPulse 2s infinite;
}

@keyframes freeShippingPulse {
    0%, 100% { 
        opacity: 1;
        transform: scale(1);
    }
    50% { 
        opacity: 0.8;
        transform: scale(0.98);
    }
}

/* تحسينات للعروض الخاصة */
.special-offer {
    border: 2px dashed #FACC15;
    animation: borderPulse 3s infinite;
}

@keyframes borderPulse {
    0%, 100% { 
        border-color: #FACC15;
    }
    50% { 
        border-color: #EAB308;
    }
}

/* تأثيرات للجودة العالية */
.premium-badge {
    background: linear-gradient(135deg, #FACC15 0%, #D97706 100%);
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}

/* تأثيرات للتوفير */
.savings-badge {
    background: linear-gradient(135deg, #EF4444 0%, #DC2626 100%);
    animation: savingsPulse 1.5s infinite;
}

@keyframes savingsPulse {
    0%, 100% { 
        transform: scale(1);
        box-shadow: 0 4px 6px rgba(239, 68, 68, 0.2);
    }
    50% { 
        transform: scale(1.05);
        box-shadow: 0 6px 8px rgba(239, 68, 68, 0.3);
    }
}