:root {
    --font-primary: 'Poppins', sans-serif;
    --font-secondary: 'Tajawal', sans-serif;
}

/* Body */
body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #f6f8fd 0%, #f1f4f9 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: background-color 0.5s ease;
    overflow: auto;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

body::-webkit-scrollbar {
    width: 8px;
}

body::-webkit-scrollbar-track {
    background: #f8bbd0;
}

body::-webkit-scrollbar-thumb {
    background-color: #d81b60;
    border-radius: 10px;
    border: 2px solid #f8bbd0;
}

/* Navigation Bar */
.navbar {
    background: rgba(255, 255, 255, 0.95) !important;
    padding: 20px 0;
    transition: all 0.5s;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.navbar.sticked {
    padding: 12px 0;
    background: rgba(255, 255, 255, 0.9) !important;
}

@keyframes slideDown {
    from { transform: translateY(-100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.navbar-brand img {
    height: 40px;
    transition: transform 0.3s ease;
}

.navbar-brand img:hover {
    transform: rotate(10deg);
}

.navbar-nav .nav-link {
    position: relative;
    padding: 5px 15px;
    font-size: 16px;
    font-weight: 500;
    color: #1a1f24;
    font-family: var(--font-primary);
    white-space: nowrap;
    transition: all 0.3s;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link:focus,
.navbar-nav .nav-link.active {
    color: #000000 !important;
    background-color: #f06292 !important;
    border-radius: 8px;
}

.navbar-nav .nav-link:before {
    content: "";
    position: absolute;
    width: 100%;
    height: 2px;
    bottom: -2px;
    left: 0;
    background-color: #d81b60;
    visibility: hidden;
    width: 0px;
    transition: all 0.3s ease-in-out;
}

.navbar-nav .nav-link:hover:before {
    visibility: visible;
    width: 100%;
}

.navbar-nav .nav-link.active:before {
    display: none;
}

.navbar .container-fluid {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.navbar-nav {
    display: flex;
    gap: 15px;
    margin: 0 auto;
}

.language-switcher {
    margin-inline-start: 1rem;
}

.navbar-brand {
    margin-inline-end: 1rem;
}

/* Adjustments for RTL */
[dir="rtl"] .navbar .container-fluid {
    flex-direction: row-reverse;
}

[dir="rtl"] .navbar-brand {
    margin-inline-end: 0;
    margin-inline-start: 1rem;
}

[dir="rtl"] .language-switcher {
    margin-inline-start: 0;
    margin-inline-end: 1rem;
}

/* Language Switcher */
.language-switcher {
    display: flex;
    align-items: center;
    animation: fadeIn 2s;
}

.form-check-input {
    margin-left: 0px;
}

/* Main Content Adjustments */
main.container {
    margin-top: 120px !important; /* Ensures content starts below fixed navbar */
    padding-top: 20px;
}

/* Table */
.table {
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.table thead {
    background-color: #f48fb1;
    color: #fff;
}

.table tbody tr:hover {
    background-color: #fce4ec;
    transition: background-color 0.3s ease;
}

.table-responsive {
    border-radius: 10px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-top: 20px;
}

.table th, .table td {
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-weight: 400;
    text-align: center;
}

/* Footer */
.footer {
    margin-top: auto;
    width: 100%;
    padding: 0;
    display: flex;
    flex-direction: column;
}

.newsletter-section {
    width: 100%;
    margin: 0;
    padding: 30px 0;
    background: #1a1f24fa;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.footer-content {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: rgba(216, 27, 96, 0.1);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: #d81b60;
    transform: translateY(-5px);
}

.social-links a img {
    width: 16px;
    height: 16px;
    filter: brightness(0) saturate(100%) invert(27%) sepia(51%) saturate(2878%) hue-rotate(320deg) brightness(95%) contrast(97%);
}

.social-links a:hover img {
    filter: brightness(0) saturate(100%) invert(100%) sepia(0%) saturate(0%) hue-rotate(93deg) brightness(103%) contrast(103%);
}

.footer-links {
    width: 100%;
    text-align: center;
}

.footer-links a {
    margin: 0 10px;
    color: #d81b60;
    text-decoration: none;
    transition: color 0.3s ease;
}

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

@keyframes fadeInFooter {
    from { opacity: 0; }
    to { opacity: 1; }
}

.footer .social-icons {
    width: 100%;
    margin-inline-start: 0;
    margin-bottom: 2px;
}

.footer-links {
    width: 100%;
    text-align: center;
    margin-top: 2px;
}

.footer-links a {
    margin: 0 10px;
    color: #d81b60;
    text-decoration: none;
    transition: color 0.3s ease;
}

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

.footer .social-icons div {
    width: 40px;
    height: 40px;
    margin: 0 15px;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.3s ease;
    opacity: 0;
    transform: scale(0.8) rotate(-10deg);
    animation: iconAppear 0.5s forwards;
}

.footer .social-icons div:nth-child(1) {
    animation-delay: 0.2s;
}

.footer .social-icons div:nth-child(2) {
    animation-delay: 0.4s;
}

.footer .social-icons div:nth-child(3) {
    animation-delay: 0.6s;
}

@keyframes iconAppear {
    to { opacity: 1; transform: scale(1) rotate(0deg); }
}

.footer .social-icons div:hover {
    transform: scale(1.3) rotate(10deg);
}

.footer .social-icons img {
    width: 20px;
    height: 20px;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { transform: translateY(-50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes bounceIn {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-30px); }
    60% { transform: translateY(-15px); }
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Buttons */
.btn-dark {
    background-color: #d81b60;
    border: none;
    border-radius: 20px;
    padding: 10px 30px;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.btn-dark:hover {
    background-color: #c2185b;
    transform: translateY(-3px);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .footer {
        flex-direction: column;
        align-items: center;
    }

    .footer .social-icons {
        margin-inline-start: 0;
        margin-bottom: 15px;
    }

    .footer-links {
        width: 100%;
    }

    .navbar-nav {
        margin: 10px 0;
    }
}

/* Apply Tajawal for Arabic (RTL) direction */
[dir="rtl"] body {
    font-family: 'Tajawal', sans-serif;
    font-weight: 300; /* Light weight */
}

[dir="rtl"] .navbar-nav .nav-link,
[dir="rtl"] .footer-links a,
[dir="rtl"] .table th,
[dir="rtl"] .table td {
    font-family: 'Tajawal', sans-serif;
}

/* Update RTL styles */
[dir="rtl"] body,
[dir="rtl"] .navbar-nav .nav-link,
[dir="rtl"] .footer-links a,
[dir="rtl"] .table th,
[dir="rtl"] .table td {
    font-family: var(--font-secondary);
}