/* Modern Footer Styles */
.modern-footer {
    background: linear-gradient(135deg, #8B0000 0%, #4A0000 100%);
    color: #ffffff;
    position: relative;
    overflow: hidden;
    direction: rtl;
    text-align: right;
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
}

.modern-footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="50" cy="50" r="1" fill="rgba(255,255,255,0.03)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    pointer-events: none;
}

.footer-main-content {
    padding: 80px 0 60px;
    position: relative;
    z-index: 2;
    width: 100%;
}

.footer-main-content .row {
    gap: 2rem;
}

.footer-main-content .col-lg-4,
.footer-main-content .col-lg-2,
.footer-main-content .col-md-6,
.footer-main-content .col-sm-6,
.footer-main-content .col-sm-12 {
    padding: 0 1.5rem;
}

.footer-brand-section {
    margin-bottom: 30px;
    direction: rtl;
    text-align: right;
}

.footer-logo {
    text-align: right;
    margin-bottom: 25px;
    direction: rtl;
}

.footer-logo-img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    margin-bottom: 15px;
    filter: brightness(0) invert(1);
    transition: transform 0.3s ease;
}

.footer-logo-img:hover {
    transform: scale(1.1);
}

.footer-brand-name {
    font-family: 'Tajawal', sans-serif;
    font-size: 28px;
    font-weight: 700;
    color: #ffffff;
    margin: 0 0 5px 0;
    text-align: right;
    direction: rtl;
}

.footer-brand-subtitle {
    font-family: 'Tajawal', sans-serif;
    font-size: 18px;
    font-weight: 400;
    color: #b8c5d6;
    margin: 0 0 20px 0;
    text-align: right;
    direction: rtl;
}

.footer-about-text {
    text-align: right;
    margin-bottom: 25px;
    direction: rtl;
}

.footer-about-text p {
    font-family: 'Tajawal', sans-serif;
    font-size: 16px;
    line-height: 1.8;
    color: #e8f0fe;
    margin: 0;
    text-align: right;
    direction: rtl;
}

.footer-social-links {
    display: flex;
    justify-content: flex-end;
    gap: 15px;
    flex-wrap: wrap;
    direction: rtl;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: #ffffff;
    font-size: 20px;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.social-link:hover {
    background: #ffffff;
    color: #1e3c72;
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    border-color: #ffffff;
}

.footer-section-title {
    font-family: 'Tajawal', sans-serif;
    font-size: 22px;
    font-weight: 600;
    color: #ffffff;
    margin: 0 0 25px 0;
    text-align: right;
    position: relative;
    padding-bottom: 8px;
    direction: rtl;
}

.footer-section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 50px;
    height: 3px;
    background: linear-gradient(90deg, #ff6b6b, #ffa500);
    border-radius: 2px;
}

.footer-links-list {
    list-style: none;
    padding: 0;
    margin: 0;
    direction: rtl;
    text-align: right;
}

.footer-links-list li {
    margin-bottom: 12px;
    direction: rtl;
    text-align: right;
}

.footer-links-list a {
    color: #e8f0fe;
    text-decoration: none;
    font-family: 'Tajawal', sans-serif;
    font-size: 16px;
    transition: all 0.3s ease;
    display: inline-block;
    position: relative;
    padding-right: 20px;
}

.footer-links-list a::before {
    content: '→';
    position: absolute;
    right: 0;
    top: 0;
    opacity: 0;
    transform: translateX(-10px);
    transition: all 0.3s ease;
    color: #ff6b6b;
}

.footer-links-list a:hover {
    color: #ffffff;
    transform: translateX(-5px);
}

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

.footer-contact-section {
    text-align: right;
}

.contact-info-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.contact-info-item {
    display: flex;
    flex-direction: row-reverse;
    align-items: flex-start;
    text-align: right;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.contact-icon:hover {
    background: #ff6b6b;
    transform: scale(1.1);
}

.contact-icon i {
    font-size: 22px;
    color: #ffffff;
}

.contact-details h5 {
    font-family: 'Tajawal', sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: #ffffff;
    margin: 0 0 8px 0;
    text-align: right;
}

.contact-details p {
    font-family: 'Tajawal', sans-serif;
    font-size: 15px;
    line-height: 1.6;
    color: #e8f0fe;
    margin: 0;
    text-align: right;
}

.contact-details a {
    color: #e8f0fe;
    text-decoration: none;
    transition: color 0.3s ease;
}

.contact-details a:hover {
    color: #ff6b6b;
}

.footer-bottom {
    background: rgba(0, 0, 0, 0.2);
    padding: 25px 0;
    position: relative;
    z-index: 2;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-copyright p {
    font-family: 'Tajawal', sans-serif;
    font-size: 15px;
    color: #b8c5d6;
    margin: 0;
    text-align: right;
}

.footer-bottom-links {
    display: flex;
    justify-content: flex-start;
    gap: 25px;
    flex-wrap: wrap;
}

.footer-bottom-links a {
    color: #b8c5d6;
    text-decoration: none;
    font-family: 'Tajawal', sans-serif;
    font-size: 14px;
    transition: all 0.3s ease;
    position: relative;
}

.footer-bottom-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: #ff6b6b;
    transition: width 0.3s ease;
}

.footer-bottom-links a:hover {
    color: #ffffff;
}

.footer-bottom-links a:hover::after {
    width: 100%;
}

/* Responsive Design */
@media (max-width: 768px) {
    .footer-main-content {
        padding: 60px 0 40px;
    }

    .footer-brand-name {
        font-size: 24px;
    }

    .footer-brand-subtitle {
        font-size: 16px;
    }

    .footer-section-title {
        font-size: 20px;
        text-align: center;
    }

    .footer-section-title::after {
        right: 50%;
        transform: translateX(50%);
    }

    .footer-links-section,
    .footer-contact-section {
        text-align: center;
        margin-bottom: 30px;
    }

    .contact-info-item {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }

    .contact-info-list {
        gap: 15px;
    }

    .contact-info-item {
        flex-direction: column;
    }

    .contact-icon {
        margin: 0 0 15px 0;
    }

    .contact-details h5,
    .contact-details p {
        text-align: right;
    }

    .footer-copyright p {
        text-align: right;
        margin-bottom: 15px;
    }

    .footer-bottom-links {
        justify-content: flex-end;
    }

    .social-link {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }
}

@media (max-width: 576px) {
    .footer-main-content {
        padding: 50px 0 30px;
    }

    .footer-logo-img {
        width: 60px;
        height: 60px;
    }

    .footer-brand-name {
        font-size: 22px;
    }

    .footer-brand-subtitle {
        font-size: 14px;
    }

    .footer-about-text p {
        font-size: 14px;
    }

    .footer-section-title {
        font-size: 18px;
    }

    .footer-links-list a {
        font-size: 14px;
    }

    .contact-details h5 {
        font-size: 16px;
    }

    .contact-details p {
        font-size: 13px;
    }
}

/* RTL Specific Adjustments */
[dir="rtl"] .footer-section-title::after {
    right: 0;
    left: auto;
}

[dir="rtl"] .footer-links-list a {
    padding-right: 0;
    padding-left: 20px;
}

[dir="rtl"] .footer-links-list a::before {
    right: auto;
    left: 0;
}

[dir="rtl"] .footer-links-list a:hover {
    transform: translateX(5px);
}

[dir="rtl"] .contact-info-item {
    flex-direction: initial;
    gap: 5px;
}

[dir="rtl"] .contact-icon {
    margin-left: 0;
    margin-right: 15px;
}

[dir="rtl"] .footer-bottom-links a::after {
    left: auto;
    right: 0;
}
