/* ==============================
   تنسيقات التذييل المحسّن
   ============================== */

/* التذييل الرئيسي */
.footer {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
    position: relative;
    overflow: hidden;
    padding: 80px 0 0;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 30%, rgba(245, 166, 35, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(46, 74, 98, 0.1) 0%, transparent 50%);
    animation: bgPulse 15s ease-in-out infinite alternate;
}

@keyframes bgPulse {
    0% { opacity: 0.5; }
    100% { opacity: 1; }
}

.footer::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--accent-color), #FFD700, var(--accent-color), transparent);
    box-shadow: 0 0 20px rgba(245, 166, 35, 0.5);
}

/* محتوى التذييل */
.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 50px;
    padding-bottom: 50px;
    border-bottom: 2px solid rgba(245, 166, 35, 0.2);
    position: relative;
    z-index: 2;
}

/* أقسام التذييل */
.footer-section {
    position: relative;
}

/* شعار التذييل */
.footer-logo {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 2rem;
    font-weight: 900;
    color: var(--white);
    margin-bottom: 20px;
    position: relative;
}

.footer-logo i {
    font-size: 2.5rem;
    color: var(--accent-color);
    filter: drop-shadow(0 0 20px rgba(245, 166, 35, 0.6));
    animation: logoGlow 3s ease-in-out infinite;
}

@keyframes logoGlow {
    0%, 100% { filter: drop-shadow(0 0 20px rgba(245, 166, 35, 0.6)); }
    50% { filter: drop-shadow(0 0 30px rgba(245, 166, 35, 0.9)); }
}

.footer-logo span {
    background: linear-gradient(135deg, #FFFFFF, var(--accent-color), #FFD700);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientMove 5s ease infinite;
}

@keyframes gradientMove {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.footer-description {
    font-size: 1.05rem;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 25px;
}

/* عناوين الأقسام */
.footer-title {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--white);
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 15px;
}

.footer-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-color), #FFD700);
    border-radius: 2px;
}

/* معلومات الاتصال */
.footer-contact-info {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.footer-contact-item {
    display: flex;
    align-items: center;
    gap: 12px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.05rem;
    transition: all 0.3s ease;
    padding: 10px;
    border-radius: 10px;
}

.footer-contact-item:hover {
    background: rgba(245, 166, 35, 0.1);
    transform: translateX(-5px);
    color: var(--white);
}

.footer-contact-item i {
    width: 35px;
    height: 35px;
    background: linear-gradient(135deg, rgba(245, 166, 35, 0.2), rgba(245, 166, 35, 0.1));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-color);
    font-size: 1.1rem;
    flex-shrink: 0;
}

.footer-contact-item a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-contact-item:hover a {
    color: var(--accent-color);
}

/* الروابط السريعة */
.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links li a {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-size: 1.05rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
    position: relative;
    padding: 8px 0;
}

.footer-links li a::before {
    content: '◀';
    font-size: 0.8rem;
    color: var(--accent-color);
    opacity: 0;
    transform: translateX(10px);
    transition: all 0.3s ease;
}

.footer-links li a:hover::before {
    opacity: 1;
    transform: translateX(0);
}

.footer-links li a:hover {
    color: var(--accent-color);
    transform: translateX(-5px);
}

/* الروابط الاجتماعية */
.social-links {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.social-link {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, rgba(245, 166, 35, 0.2), rgba(245, 166, 35, 0.1));
    border: 2px solid rgba(245, 166, 35, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.3rem;
    text-decoration: none;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.social-link::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, var(--accent-color), #FFD700);
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.social-link i {
    position: relative;
    z-index: 2;
    transition: transform 0.3s ease;
}

.social-link:hover::before {
    opacity: 1;
}

.social-link:hover {
    transform: translateY(-8px) rotate(360deg) scale(1.1);
    box-shadow: 0 10px 30px rgba(245, 166, 35, 0.5);
    border-color: #FFD700;
}

.social-link:hover i {
    transform: scale(1.2);
}

/* النشرة البريدية */
.newsletter-form {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.newsletter-input {
    flex: 1;
    padding: 14px 20px;
    background: rgba(255, 255, 255, 0.08);
    border: 2px solid rgba(245, 166, 35, 0.3);
    border-radius: 30px;
    color: var(--white);
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
}

.newsletter-input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.newsletter-input:focus {
    background: rgba(255, 255, 255, 0.12);
    border-color: var(--accent-color);
    box-shadow: 0 0 20px rgba(245, 166, 35, 0.3);
}

.newsletter-btn {
    padding: 14px 30px;
    background: linear-gradient(135deg, var(--accent-color), #D98E19);
    border: none;
    border-radius: 30px;
    color: var(--white);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.newsletter-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 25px rgba(245, 166, 35, 0.5);
}

/* أسفل التذييل */
.footer-bottom {
    padding: 30px 0;
    text-align: center;
    position: relative;
    z-index: 2;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 1rem;
    margin: 0;
}

.footer-bottom-links {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.footer-bottom-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

.footer-bottom-links a:hover {
    color: var(--accent-color);
}

/* زر العودة للأعلى */
.back-to-top {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 55px;
    height: 55px;
    background: linear-gradient(135deg, var(--accent-color), #D98E19);
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.5rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
    z-index: 999;
    box-shadow: 0 8px 25px rgba(245, 166, 35, 0.4);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: 0 12px 35px rgba(245, 166, 35, 0.6);
}

/* التصميم المتجاوب */
@media (max-width: 992px) {
    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: 40px;
    }
}

@media (max-width: 768px) {
    .footer {
        padding: 60px 0 0;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 35px;
    }
    
    .footer-title::after {
        right: auto;
        left: 0;
    }
    
    .newsletter-form {
        flex-direction: column;
    }
    
    .newsletter-btn {
        width: 100%;
    }
    
    .social-links {
        justify-content: flex-start;
    }
}

@media (max-width: 480px) {
    .footer-logo {
        font-size: 1.6rem;
    }
    
    .footer-logo i {
        font-size: 2rem;
    }
    
    .footer-title {
        font-size: 1.2rem;
    }
    
    .back-to-top {
        bottom: 20px;
        left: 20px;
        width: 50px;
        height: 50px;
    }
}
