/* تأثيرات إضافية للتصميم الزجاجي */

/* تأثير النجوم المتلألئة */
.stars {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
}

.star {
    position: absolute;
    background-color: rgba(255, 255, 255, 0.7);
    border-radius: 50%;
    animation: twinkle var(--duration) ease-in-out infinite;
    opacity: 0;
}

@keyframes twinkle {

    0%,
    100% {
        opacity: 0;
        transform: scale(0.5);
    }

    50% {
        opacity: 1;
        transform: scale(1);
    }
}

/* تأثير الموجات */
.waves {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 200px;
    z-index: 0;
    overflow: hidden;
}

.wave {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 200%;
    height: 100%;
    background: url('data:image/svg+xml;utf8,<svg viewBox="0 0 1200 120" xmlns="http://www.w3.org/2000/svg"><path d="M0 0v46.29c47.79 22.2 103.59 32.17 158 28 70.36-5.37 136.33-33.31 206.8-37.5 73.84-4.36 147.54 16.88 218.2 35.26 69.27 18 138.3 24.88 209.4 13.08 36.15-6 69.85-17.84 104.45-29.34C989.49 25 1113-14.29 1200 52.47V0z" fill="%23ffffff" fill-opacity="0.1"/></svg>') repeat-x;
    background-size: 1200px 100px;
    animation: wave 20s linear infinite;
}

.wave:nth-child(2) {
    bottom: 10px;
    opacity: 0.5;
    animation-delay: 5s;
    animation-duration: 15s;
}

.wave:nth-child(3) {
    bottom: 20px;
    opacity: 0.2;
    animation-delay: 10s;
    animation-duration: 25s;
}

@keyframes wave {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* تأثير الضباب */
.fog {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0, 32, 80, 0) 0%, rgba(30, 64, 175, 0.05) 100%);
    z-index: 0;
    animation: fog 20s ease-in-out infinite alternate;
}

@keyframes fog {
    0% {
        opacity: 0.3;
    }

    100% {
        opacity: 0.7;
    }
}

/* تحسينات للبطاقة الزجاجية */
.glass-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.glass-card:hover {
    box-shadow: 0 15px 40px 0 rgba(0, 32, 80, 0.5);
}

/* تأثير النبض للزر */
.login-btn {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(65, 105, 225, 0.4);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(65, 105, 225, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(65, 105, 225, 0);
    }
}

/* تأثير الاهتزاز للحقول غير الصالحة */
.shake {
    animation: shake 0.6s ease-in-out;
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    10%,
    30%,
    50%,
    70%,
    90% {
        transform: translateX(-5px);
    }

    20%,
    40%,
    60%,
    80% {
        transform: translateX(5px);
    }
}

/* تحسينات للأجهزة المحمولة */
@media (max-width: 768px) {

    /* تقليل حجم وتأثير الموجات */
    .waves {
        height: 150px;
    }

    .wave {
        background-size: 800px 80px;
    }

    /* تقليل عدد النجوم للأداء الأفضل */
    .star {
        opacity: 0.7;
    }

    /* تقليل تأثير الدوران ثلاثي الأبعاد على الهاتف */
    .glass-card {
        transform: none !important;
        transition: box-shadow 0.3s ease;
    }

    /* تحسين تأثير النبض للزر */
    .login-btn {
        animation: pulse 3s infinite;
    }

    @keyframes pulse {
        0% {
            box-shadow: 0 0 0 0 rgba(65, 105, 225, 0.3);
        }

        70% {
            box-shadow: 0 0 0 7px rgba(65, 105, 225, 0);
        }

        100% {
            box-shadow: 0 0 0 0 rgba(65, 105, 225, 0);
        }
    }
}

/* تحسينات إضافية للهواتف الصغيرة */
@media (max-width: 576px) {

    /* تقليل حجم وتأثير الموجات */
    .waves {
        height: 100px;
    }

    .wave {
        background-size: 600px 60px;
    }

    /* تقليل تأثير الضباب */
    .fog {
        opacity: 0.5;
    }
}