/* تأثيرات متقدمة */

/* تأثيرات الانتقال بين الأقسام */
.section-transition {
    position: relative;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.645, 0.045, 0.355, 1);
}

.section-transition.visible {
    opacity: 1;
    transform: translateY(0);
}

/* تأثير الظهور التدريجي للأقسام */
.section-reveal {
    clip-path: polygon(0 0, 100% 0, 100% 0, 0 0);
    transition: clip-path 1.2s cubic-bezier(0.77, 0, 0.175, 1);
}

.section-reveal.visible {
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
}

/* تأثير التمرير السلس */
html {
    scroll-behavior: smooth;
}

.smooth-scroll-section {
    position: relative;
    will-change: transform;
}

/* تأثير Parallax محسن */
.parallax {
    transform: translateZ(0);
    transition: transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
    will-change: transform;
}

.parallax-container {
    perspective: 1000px;
    overflow: hidden;
}

/* تأثيرات الأرقام */
@property --num {
    syntax: "<integer>";
    initial-value: 0;
    inherits: false;
}

.animate-number {
    animation: counter 2s forwards;
    counter-reset: num var(--num);
}

.animate-number::after {
    content: counter(num);
}

@keyframes counter {
    from {
        --num: 0;
    }
    to {
        --num: attr(data-value);
    }
}

/* Skeleton Loading */
.skeleton {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0.05) 25%,
        rgba(255, 255, 255, 0.1) 37%,
        rgba(255, 255, 255, 0.05) 63%
    );
    background-size: 400% 100%;
    animation: skeleton-loading 1.4s ease infinite;
}

@keyframes skeleton-loading {
    0% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0 50%;
    }
}

/* تأثيرات متقدمة للبطاقات */
.card-3d {
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.card-3d:hover {
    transform: rotateY(5deg) rotateX(-5deg) translateZ(10px);
}

/* تأثيرات الصور */
.image-hover {
    position: relative;
    overflow: hidden;
}

.image-hover img {
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1),
                filter 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.image-hover:hover img {
    transform: scale(1.05);
    filter: brightness(1.1);
}

/* تأثيرات النص */
.text-gradient {
    background: linear-gradient(135deg, #D4AF37 0%, #6E56CF 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: gradient-shift 8s ease infinite;
}

@keyframes gradient-shift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* تأثيرات التمرير */
.scroll-indicator {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(to right, #D4AF37, #6E56CF);
    transform-origin: 0 50%;
    transition: transform 0.2s ease;
    z-index: 1000;
}

/* تأثيرات القائمة */
.menu-item {
    position: relative;
    transition: color 0.3s ease;
}

.menu-item::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, #D4AF37, #6E56CF);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.menu-item:hover::after {
    transform: scaleX(1);
    transform-origin: left;
}

/* تأثيرات الأزرار */
.button-glow {
    position: relative;
    overflow: hidden;
}

.button-glow::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(212, 175, 55, 0.2) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.button-glow:hover::before {
    opacity: 1;
    animation: glow-rotate 2s linear infinite;
}

@keyframes glow-rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* تأثيرات الخلفية */
.dynamic-background {
    position: relative;
    overflow: hidden;
}

.dynamic-background::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at var(--mouse-x, 50%) var(--mouse-y, 50%), 
                rgba(212, 175, 55, 0.1), 
                transparent 40%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.dynamic-background:hover::before {
    opacity: 1;
}