/* ============================================
   TechHub Platform — COMPLETE STYLESHEET
   BRAND COLORS: Red (#E31837) | Black (#1A1A1A) | White (#FFFFFF)
   SOURCE: https://techhub.af/
   ============================================ */

/* ---------- GENERAL RESET ---------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    line-height: 1.6;
    background-color: #f5f5f5;
    color: #333;
    top: 0 !important;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ---------- HEADER & NAVIGATION ---------- */
header {
    background: #1A1A1A;
    color: #fff;
    padding: 10px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 3px solid #E31837;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

/* ---------- LOGO ---------- */
.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-img {
    height: 60px;
    width: auto;
    max-width: 80px;
    object-fit: contain;
}

.logo-text h1 {
    font-size: 1.8rem;
    letter-spacing: 2px;
    color: #E31837;
    font-weight: 700;
    line-height: 1;
}

.logo-text p {
    font-size: 0.7rem;
    color: #FFFFFF;
    letter-spacing: 3px;
    font-weight: 600;
    margin: 2px 0;
}

.logo-text span {
    font-size: 0.6rem;
    color: #CCCCCC;
    letter-spacing: 1px;
    display: block;
}

/* ---------- NAVIGATION ---------- */
nav {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 20px;
}

nav ul li a {
    color: #fff;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
    padding: 5px 0;
    font-size: 0.95rem;
}

nav ul li a:hover {
    color: #E31837;
}

/* ---------- LANGUAGE SELECTOR ---------- */
.language-selector {
    margin-left: 15px;
    min-width: 160px;
}

nav select {
    padding: 8px 12px;
    border: 2px solid #E31837;
    border-radius: 4px;
    background: #fff;
    color: #1A1A1A;
    font-weight: 500;
    cursor: pointer;
    font-size: 14px;
    min-width: 150px;
}

nav select:hover {
    background: #E31837;
    color: #fff;
}

/* ---------- BUTTONS ---------- */
.btn {
    display: inline-block;
    padding: 12px 30px;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background: #E31837;
    color: #fff;
}

.btn-primary:hover {
    background: #C41630;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(227, 24, 55, 0.4);
}

.btn-secondary {
    background: transparent;
    color: #E31837;
    border: 2px solid #E31837;
}

.btn-secondary:hover {
    background: #E31837;
    color: #fff;
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: #fff;
    border: 2px solid #fff;
}

.btn-outline:hover {
    background: #E31837;
    color: #fff;
    border-color: #E31837;
}

/* ---------- HERO SECTION ---------- */
.hero {
    background: linear-gradient(135deg, #1A1A1A 0%, #2A2A2A 100%);
    color: #fff;
    padding: 80px 40px;
    border-radius: 10px;
    text-align: center;
    margin-bottom: 40px;
    position: relative;
    overflow: hidden;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 500px;
    height: 500px;
    border-radius: 50%;
    background: rgba(227, 24, 55, 0.05);
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    line-height: 1.2;
    position: relative;
    z-index: 1;
}

.hero h1 .highlight {
    color: #E31837;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    opacity: 0.9;
    color: #CCCCCC;
    position: relative;
    z-index: 1;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

/* ---------- STATS SECTION ---------- */
.stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin: 40px 0;
}

.stat-item {
    background: #fff;
    padding: 24px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    border-bottom: 3px solid #E31837;
}

.stat-number {
    font-size: 36px;
    font-weight: 800;
    color: #E31837;
}

.stat-label {
    color: #555;
    font-size: 14px;
    font-weight: 500;
}

/* ---------- FEATURES / WHY CHOOSE ---------- */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature {
    text-align: center;
    padding: 30px 20px;
    border-radius: 10px;
    transition: all 0.3s ease;
    background: #f5f5f5;
}

.feature:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    background: #fff;
    border-bottom: 3px solid #E31837;
}

.feature .icon {
    font-size: 3rem;
    color: #E31837;
    margin-bottom: 15px;
    display: block;
}

.feature h3 {
    font-size: 1.3rem;
    color: #1A1A1A;
    margin-bottom: 10px;
}

.feature p {
    color: #666;
}

/* ---------- SECTION TITLES ---------- */
h2 {
    font-size: 2.5rem;
    color: #1A1A1A;
    margin-bottom: 10px;
    text-align: center;
}

h2 .highlight {
    color: #E31837;
}

h2 + p {
    text-align: center;
    color: #555;
    margin-bottom: 40px;
}

/* ---------- CARDS ---------- */
.card {
    background: #FFFFFF;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
    border-bottom: 3px solid transparent;
    padding: 20px;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    border-bottom: 3px solid #E31837;
}

.card .icon {
    font-size: 2.5rem;
    color: #E31837;
    margin-bottom: 15px;
    display: block;
}

.card-title {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: #1A1A1A;
}

.card p {
    color: #666;
    margin-bottom: 15px;
}

/* ---------- GRID ---------- */
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.grid-3 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 24px;
}

.grid-4 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr 1fr;
    gap: 24px;
}

/* ---------- FORMS ---------- */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
    color: #1A1A1A;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: #E31837;
    outline: none;
    box-shadow: 0 0 0 3px rgba(227, 24, 55, 0.2);
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

/* ---------- ALERT MESSAGES ---------- */
.alert {
    padding: 15px 20px;
    border-radius: 5px;
    margin-bottom: 20px;
    border-right: 4px solid;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border-color: #28a745;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border-color: #E31837;
}

.alert-info {
    background: #d1ecf1;
    color: #0c5460;
    border-color: #17a2b8;
}

/* ---------- PAGE HEADER ---------- */
.page-header {
    background: linear-gradient(135deg, #1A1A1A 0%, #2A2A2A 100%);
    padding: 50px 0;
    text-align: center;
    border-bottom: 3px solid #E31837;
    margin-bottom: 40px;
}

.page-header h1 {
    font-size: 2.8rem;
    color: #FFFFFF;
}

.page-header h1 .highlight {
    color: #E31837;
}

.page-header p {
    font-size: 1.1rem;
    color: #CCCCCC;
}

/* ---------- FOOTER ---------- */
footer {
    background: #1A1A1A;
    color: #fff;
    padding: 40px 0 20px;
    margin-top: 40px;
    border-top: 3px solid #E31837;
}

footer .container {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
}

footer h3, footer h4 {
    color: #E31837;
    margin-bottom: 15px;
}

footer h3 {
    font-size: 1.5rem;
}

footer h3 span {
    color: #fff;
}

footer a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s;
}

footer a:hover {
    color: #E31837;
}

footer ul {
    list-style: none;
    padding: 0;
}

footer ul li {
    margin-bottom: 8px;
}

footer .copyright {
    grid-column: 1 / -1;
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    margin-top: 20px;
    font-size: 14px;
    color: #888;
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 992px) {
    .grid-4 {
        grid-template-columns: 1fr 1fr;
    }
    .stats {
        grid-template-columns: 1fr 1fr;
    }
    footer .container {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .grid-2,
    .grid-3 {
        grid-template-columns: 1fr;
    }
    
    .grid-4 {
        grid-template-columns: 1fr;
    }
    
    .stats {
        grid-template-columns: 1fr;
    }
    
    footer .container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    header .container {
        flex-direction: column;
        gap: 15px;
    }
    
    nav ul {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .hero {
        padding: 40px 20px;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .btn {
        width: 100%;
        text-align: center;
    }
    
    .page-header h1 {
        font-size: 2rem;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1rem;
    }
    
    h2 {
        font-size: 2rem;
    }
    
    .logo-text h1 {
        font-size: 1.2rem;
    }
    
    nav ul li a {
        font-size: 0.85rem;
    }
}

/* ============================================
   LANGUAGE DROPDOWN - HOVER BASED
   ============================================ */

/* ===== LANGUAGE DROPDOWN ===== */
.lang-dropdown {
    position: relative;
    display: inline-block;
}

.lang-dropdown .lang-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    transition: all 0.3s ease;
    color: #ffffff;
    font-weight: 500;
    font-size: 14px;
    user-select: none;
}

.lang-dropdown .lang-toggle:hover {
    background: rgba(227, 24, 55, 0.15);
    border-color: #E31837;
}

.lang-dropdown .lang-toggle .lang-name {
    font-size: 13px;
    font-weight: 500;
}

.lang-dropdown .lang-toggle .dropdown-arrow {
    font-size: 10px;
    margin-left: 2px;
    opacity: 0.6;
    transition: transform 0.3s ease;
}

.lang-dropdown:hover .lang-toggle .dropdown-arrow {
    transform: rotate(180deg);
}

/* ===== DROPDOWN MENU ===== */
.lang-dropdown .lang-dropdown-menu {
    display: none !important;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 160px;
    padding: 6px 0;
    background: #1A1A2E;
    border-radius: 10px;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-top: 3px solid #E31837;
    z-index: 1000;
    list-style: none;
    margin: 0;
}

/* Show on hover - Desktop only */
@media (min-width: 769px) {
    .lang-dropdown:hover .lang-dropdown-menu {
        display: block !important;
        animation: dropdownFade 0.2s ease-out;
    }
}

.lang-dropdown .lang-dropdown-menu li {
    display: block;
    width: 100%;
}

.lang-dropdown .lang-dropdown-menu li a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 18px;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.lang-dropdown .lang-dropdown-menu li a:hover {
    background: rgba(227, 24, 55, 0.12);
    color: #E31837;
}

.lang-dropdown .lang-dropdown-menu li a.active {
    background: rgba(227, 24, 55, 0.12);
    color: #E31837;
}

.lang-dropdown .lang-dropdown-menu li a .lang-check {
    color: #10B981;
    font-weight: 700;
    font-size: 14px;
    margin-left: 10px;
}

/* ===== RTL SUPPORT ===== */
body.rtl .lang-dropdown .lang-dropdown-menu {
    left: 0;
    right: auto;
}

body.rtl .lang-dropdown .lang-toggle {
    flex-direction: row-reverse;
}

body.rtl .lang-dropdown .lang-toggle .dropdown-arrow {
    margin-left: 0;
    margin-right: 2px;
}

body.rtl .lang-dropdown .lang-dropdown-menu li a .lang-check {
    margin-left: 0;
    margin-right: 10px;
}

/* ===== MOBILE RESPONSIVE ===== */
@media (max-width: 768px) {
    .lang-dropdown {
        width: 100%;
    }
    
    .lang-dropdown .lang-toggle {
        width: 100%;
        justify-content: center;
    }
    
    .lang-dropdown .lang-dropdown-menu {
        position: static !important;
        box-shadow: none !important;
        padding-left: 20px !important;
        border-left: 2px solid #E31837 !important;
        border-top: none !important;
        border-radius: 0 !important;
        width: 100% !important;
        min-width: auto !important;
        background: rgba(255, 255, 255, 0.03) !important;
        margin-left: 0 !important;
        border: none !important;
    }
    
    body.rtl .lang-dropdown .lang-dropdown-menu {
        padding-left: 0 !important;
        padding-right: 20px !important;
        border-left: none !important;
        border-right: 2px solid #E31837 !important;
    }
    
    .lang-dropdown .lang-dropdown-menu li a {
        padding: 8px 16px !important;
        justify-content: flex-start;
    }
    
    .lang-dropdown .lang-dropdown-menu li a .lang-check {
        margin-left: auto;
    }
    
    /* Show on click for mobile */
    .lang-dropdown .lang-dropdown-menu.show {
        display: block !important;
    }
    
    .lang-dropdown:hover .lang-dropdown-menu {
        display: none !important;
    }
}

/* ===== ANIMATION ===== */
@keyframes dropdownFade {
    from {
        opacity: 0;
        transform: translateY(-8px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ============================================
   RTL / PERSIAN / DARI / PASHTO FONT SUPPORT
   ============================================ */

/* RTL language settings */
body.rtl-lang {
    font-family: 'Noto Sans Arabic', 'Amiri', 'Scheherazade New', 'Lateef', 'Segoe UI', Tahoma, sans-serif;
    text-align: right;
    letter-spacing: 0.3px;
}

body.rtl-lang h1,
body.rtl-lang h2,
body.rtl-lang h3,
body.rtl-lang h4 {
    font-family: 'Noto Sans Arabic', 'Amiri', 'Scheherazade New', serif;
    letter-spacing: 0.5px;
}

body.rtl-lang p,
body.rtl-lang li,
body.rtl-lang .content {
    font-family: 'Noto Sans Arabic', 'Amiri', 'Scheherazade New', serif;
    line-height: 1.9;
}

/* Fix for Persian/Dari specific characters */
body.rtl-lang .content ul,
body.rtl-lang .content ol {
    padding-right: 24px;
    padding-left: 0;
}

body.rtl-lang .content ul li,
body.rtl-lang .content ol li {
    text-align: right;
}

/* Adjust course cards for RTL */
body.rtl-lang .course-card-flip .flip-front,
body.rtl-lang .course-card-flip .flip-back {
    direction: rtl;
    text-align: right;
}

body.rtl-lang .course-card-flip .flip-front .course-badge {
    right: auto;
    left: 8px;
}

/* Fix for numbers in RTL (keep LTR for numbers) */
body.rtl-lang .price,
body.rtl-lang .number,
body.rtl-lang .rating,
body.rtl-lang .duration {
    direction: ltr;
    display: inline-block;
}

/* Better readability for Persian/Dari */
body.rtl-lang .hero-content h1 {
    font-family: 'Noto Sans Arabic', 'Amiri', serif;
    line-height: 1.4;
}

body.rtl-lang .hero-content .hero-text {
    font-family: 'Noto Sans Arabic', 'Amiri', serif;
    line-height: 2;
}

/* Dropdown menus in RTL */
body.rtl-lang .dropdown-menu {
    text-align: right;
}

body.rtl-lang .dropdown-menu li a {
    text-align: right;
    direction: rtl;
}

/* Fix for buttons in RTL */
body.rtl-lang .btn,
body.rtl-lang .btn-sm {
    direction: rtl;
}

/* Fix for forms in RTL */
body.rtl-lang input,
body.rtl-lang textarea,
body.rtl-lang select {
    direction: rtl;
    text-align: right;
}

/* Fix for meta row in RTL */
body.rtl-lang .meta-row {
    direction: rtl;
}

/* Floating cards in RTL */
body.rtl-lang .floating-card {
    direction: rtl;
    text-align: right;
}

/* Testimonials in RTL */
body.rtl-lang .testimonial-card {
    direction: rtl;
    text-align: right;
}

body.rtl-lang .testimonial-card::before {
    right: auto;
    left: 20px;
}

body.rtl-lang .testimonial-card .author {
    direction: rtl;
}

body.rtl-lang .testimonial-card .author .info {
    text-align: right;
}

/* ============================================
   FONT-FACE FALLBACK (If Google Fonts fail)
   ============================================ */
@font-face {
    font-family: 'LocalArabic';
    src: local('Arabic Typesetting'),
         local('Arial Unicode MS'),
         local('Tahoma');
    font-weight: normal;
    font-style: normal;
}

/* Fallback for RTL when web fonts don't load */
body.rtl-lang .fallback-font {
    font-family: 'Arabic Typesetting', 'Arial Unicode MS', 'Tahoma', 'Noto Sans Arabic', serif;
}

/* ============================================
   LOCAL FONT FACE DECLARATIONS
   ============================================ */

/* Noto Sans Arabic */
@font-face {
    font-family: 'NotoSansArabic';
    src: url('../assets/fonts/NotoSansArabic-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'NotoSansArabic';
    src: url('../assets/fonts/NotoSansArabic-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'NotoSansArabic';
    src: url('../assets/fonts/NotoSansArabic-Light.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

/* Amiri - Classic Arabic Font */
@font-face {
    font-family: 'Amiri';
    src: url('../assets/fonts/Amiri-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Amiri';
    src: url('../assets/fonts/Amiri-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* Scheherazade New - Professional Arabic */
@font-face {
    font-family: 'ScheherazadeNew';
    src: url('../assets/fonts/ScheherazadeNew-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'ScheherazadeNew';
    src: url('../assets/fonts/ScheherazadeNew-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* Lateef - Modern Arabic */
@font-face {
    font-family: 'Lateef';
    src: url('../assets/fonts/Lateef-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

/* ============================================
   BODY FONT SETTINGS
   ============================================ */

/* Default body font */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* RTL specific styles for Dari and Pashto */
body[dir="rtl"],
body.rtl-lang {
    font-family: 'NotoSansArabic', 'Amiri', 'ScheherazadeNew', 'Lateef', 'Segoe UI', Tahoma, sans-serif;
    text-align: right;
    line-height: 1.8;
    font-size: 16px;
}

/* LTR specific styles for English */
body[dir="ltr"] {
    font-family: 'Segoe UI', 'NotoSansArabic', Tahoma, Geneva, Verdana, sans-serif;
    text-align: left;
}

/* Headings in RTL */
body[dir="rtl"] h1,
body[dir="rtl"] h2,
body[dir="rtl"] h3,
body[dir="rtl"] h4,
body[dir="rtl"] h5,
body[dir="rtl"] h6,
body.rtl-lang h1,
body.rtl-lang h2,
body.rtl-lang h3,
body.rtl-lang h4 {
    font-family: 'NotoSansArabic', 'Amiri', 'ScheherazadeNew', serif;
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* Content text in RTL */
body[dir="rtl"] p,
body[dir="rtl"] li,
body[dir="rtl"] .content,
body[dir="rtl"] .text,
body[dir="rtl"] .description,
body.rtl-lang p,
body.rtl-lang li,
body.rtl-lang .content {
    font-family: 'NotoSansArabic', 'Amiri', 'ScheherazadeNew', 'Lateef', serif;
    line-height: 2;
    font-size: 16px;
}

/* Course cards in RTL */
body[dir="rtl"] .course-card-flip .flip-front h3,
body[dir="rtl"] .course-card-flip .flip-back p,
body.rtl-lang .course-card-flip .flip-front h3,
body.rtl-lang .course-card-flip .flip-back p {
    font-family: 'NotoSansArabic', 'Amiri', 'ScheherazadeNew', serif;
}

/* Hero section in RTL */
body[dir="rtl"] .hero-content h1,
body.rtl-lang .hero-content h1 {
    font-family: 'NotoSansArabic', 'Amiri', 'ScheherazadeNew', serif;
    font-weight: 800;
    line-height: 1.4;
}

body[dir="rtl"] .hero-content .hero-text,
body.rtl-lang .hero-content .hero-text {
    font-family: 'NotoSansArabic', 'Amiri', 'ScheherazadeNew', 'Lateef', serif;
    line-height: 2;
}

/* Section titles in RTL */
body[dir="rtl"] .section-title h2,
body.rtl-lang .section-title h2 {
    font-family: 'NotoSansArabic', 'Amiri', 'ScheherazadeNew', serif;
    font-weight: 800;
}

/* Testimonials in RTL */
body[dir="rtl"] .testimonial-card .text,
body.rtl-lang .testimonial-card .text {
    font-family: 'NotoSansArabic', 'Amiri', 'ScheherazadeNew', 'Lateef', serif;
    line-height: 2;
}

/* Fix for numbers in RTL (keep LTR for numbers) */
body[dir="rtl"] .price,
body[dir="rtl"] .number,
body[dir="rtl"] .rating,
body[dir="rtl"] .duration,
body[dir="rtl"] .date,
body.rtl-lang .price,
body.rtl-lang .number,
body.rtl-lang .rating,
body.rtl-lang .duration,
body.rtl-lang .date {
    direction: ltr !important;
    display: inline-block;
    unicode-bidi: embed;
}

/* Fix for buttons in RTL */
body[dir="rtl"] .btn,
body[dir="rtl"] .btn-sm,
body[dir="rtl"] .btn-learn,
body.rtl-lang .btn,
body.rtl-lang .btn-sm,
body.rtl-lang .btn-learn {
    direction: rtl;
    text-align: center;
}

/* Fix for lists in RTL */
body[dir="rtl"] ul,
body[dir="rtl"] ol,
body.rtl-lang ul,
body.rtl-lang ol {
    padding-right: 24px;
    padding-left: 0;
}

body[dir="rtl"] ul li,
body[dir="rtl"] ol li,
body.rtl-lang ul li,
body.rtl-lang ol li {
    text-align: right;
    direction: rtl;
}

/* Fix for forms in RTL */
body[dir="rtl"] input,
body[dir="rtl"] textarea,
body[dir="rtl"] select,
body.rtl-lang input,
body.rtl-lang textarea,
body.rtl-lang select {
    direction: rtl;
    text-align: right;
}

/* Fix for meta row in RTL */
body[dir="rtl"] .meta-row,
body.rtl-lang .meta-row {
    direction: rtl;
}

body[dir="rtl"] .meta-row span,
body.rtl-lang .meta-row span {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

/* Floating cards in RTL */
body[dir="rtl"] .floating-card,
body.rtl-lang .floating-card {
    direction: rtl;
    text-align: right;
}

/* Dropdown menus in RTL */
body[dir="rtl"] .dropdown-menu,
body.rtl-lang .dropdown-menu {
    text-align: right;
}

body[dir="rtl"] .dropdown-menu li a,
body.rtl-lang .dropdown-menu li a {
    text-align: right;
    direction: rtl;
}

/* ============================================
   FONT FALLBACK (If local fonts fail)
   ============================================ */
.font-fallback {
    font-family: 'Arabic Typesetting', 'Arial Unicode MS', 'Tahoma', 'Segoe UI', sans-serif;
}