:root {
    --primary-color: #1977cc;
    --secondary-color: #1977cc;
    --accent-color: #FFD700; /* Subtle gold for highlights */
    --bg-color: #f0f4f7;
    --text-color: #1a2c3e;
    --light-text-color: #4a6272;
    --white: #ffffff;
    --shadow-light: 0 4px 15px rgba(0, 0, 0, 0.05);
    --shadow-dark: 0 10px 30px rgba(0, 0, 0, 0.1);
    --border-radius: 20px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* RTL Support */
[dir="rtl"] {
    font-family: 'Tajawal', 'Poppins', sans-serif;
}

body {
    font-family: 'Poppins', 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    scroll-behavior: smooth;
}

.container {
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 40px;
}

/* header & nav */
header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-light);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo h1 {
    font-size: 2rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    display: flex;
    align-items: center;
    gap: 10px;
    white-space: nowrap;
}

.logo i {
    color: var(--primary-color);
}

.logo span {
    font-size: 0.9rem;
    font-weight: 500;
    color: #0b4f8a;
    background: #dbeeff;
    padding: 4px 10px;
    border-radius: 20px;
    vertical-align: middle;
}

.logo-tagline {
    font-size: 0.7rem;
    color: var(--light-text-color);
    font-weight: 400;
    margin-top: -4px;
    letter-spacing: 0.3px;
}

.nav-links {
    display: flex;
    gap: 25px;
    list-style: none;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    font-weight: 500;
    color: var(--text-color);
    transition: 0.3s;
    font-size: 1rem;
}

.nav-links a:hover {
    color: var(--secondary-color);
}

.btn-outline-sm {
    border: 2px solid var(--secondary-color);
    background: transparent;
    padding: 8px 20px;
    border-radius: 30px;
    font-weight: 600;
    color: var(--secondary-color);
}

.lang-btn {
    background: #dbeeff;
    color: #0b4f8a;
    border: 1px solid #0b4f8a;
    padding: 5px 12px;
    border-radius: 15px;
    cursor: pointer;
    font-weight: 600;
    font-family: inherit;
    transition: 0.3s;
    margin-left: 10px;
}

.btn-outline-sm:hover {
    background: var(--secondary-color);
    color: white;
}

/* Buttons */
.btn {
    padding: 14px 30px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    border: none;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: #094c4c;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(11, 94, 94, 0.3);
}

.btn-secondary {
    background: white;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background: #eef7f6;
}

/* Hero Section with Video Background */
.hero {
    position: relative;
    height: 90vh;
    color: white;
    display: flex;
    align-items: center;
    overflow: hidden;
    z-index: 0;
    isolation: isolate;
}

.video-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(25, 119, 204, 0.72), rgba(25, 119, 204, 0.42));
    z-index: 1;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 8px 16px;
    border-radius: 30px;
    font-weight: 600;
    margin-bottom: 25px;
    display: inline-block;
}

.hero-badge i {
    color: var(--accent-color);
    margin-right: 8px;
}

[dir="rtl"] .hero-badge i {
    margin-right: 0;
    margin-left: 8px;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 25px;
}

.hero p {
    font-size: 1.3rem;
    margin-bottom: 40px;
    opacity: 0.9;
}

.hero-btns {
    display: flex;
    gap: 20px;
    justify-content: center;
}

/* Sections */
section {
    padding: 100px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--light-text-color);
    max-width: 700px;
    margin: 0 auto;
}

/* Feature Cards */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
}

.card {
    background: var(--white);
    border-radius: var(--border-radius);
    padding: 40px;
    box-shadow: var(--shadow-light);
    transition: 0.3s;
    border: 1px solid transparent;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transform: scaleX(0);
    transition: 0.3s;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-dark);
    border-color: #eee;
}

.card:hover::before {
    transform: scaleX(1);
}

.card-icon {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 25px;
}

.card h3 {
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--text-color);
}

.card p {
    font-size: 1rem;
    color: var(--light-text-color);
    margin-bottom: 20px;
}

.card .btn-text {
    color: var(--secondary-color);
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

/* Two Column Layout */
.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.col-image img {
    width: 100%;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-dark);
}

.feature-list {
    list-style: none;
    margin-top: 30px;
}

.feature-list li {
    font-size: 1.1rem;
    color: var(--light-text-color);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.feature-list li i {
    color: #2c7a4d;
    font-size: 1.3rem;
}

[dir="rtl"] .feature-list li i {
    margin-right: 0;
    margin-left: 10px;
}

/* Enrollment Section */
#enroll {
    background-color: var(--white);
    border-radius: 40px;
    padding: 80px;
    box-shadow: var(--shadow-dark);
    margin-top: -50px;
    position: relative;
    z-index: 10;
}

.enroll-split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
}

.enroll-info h3 {
    font-size: 2.2rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

/* ── Fix: keep phone/email/address LTR in RTL mode ── */
[dir="rtl"] .enroll-info p {
    direction: ltr;
    text-align: right;
}

.form-group {
    margin-bottom: 20px;
}

input, select, textarea {
    width: 100%;
    padding: 16px 20px;
    border: 1px solid #ddd;
    border-radius: 30px;
    font-family: inherit;
    font-size: 1rem;
    background: #f9f9f9;
}

.file-upload-box {
    width: 100%;
    padding: 16px 20px;
    border: 1px solid #ddd;
    border-radius: 30px;
    font-family: inherit;
    font-size: 1rem;
    background: #f9f9f9;
    display: flex;
    align-items: center;
    gap: 12px;
}

.file-upload-label {
    color: var(--light-text-color);
    font-weight: 500;
    white-space: nowrap;
}

.file-upload-box input[type="file"] {
    padding: 0;
    border: 0;
    background: transparent;
    border-radius: 0;
}

.file-upload-box input[type="file"]::-webkit-file-upload-button,
.file-upload-box input[type="file"]::file-selector-button {
    padding: 10px 16px;
    border: none;
    border-radius: 20px;
    background: var(--primary-color);
    color: var(--white);
    font-weight: 600;
    cursor: pointer;
    margin-right: 12px;
}

input:focus, select:focus, textarea:focus,
.file-upload-box:focus-within {
    outline: none;
    border-color: var(--secondary-color);
    background: white;
}

textarea {
    border-radius: 20px;
    height: 120px;
    resize: vertical;
}

.btn-form {
    width: 100%;
    justify-content: center;
}

/* Footer */
footer {
    background: #081a1f;
    color: #cbdbe0;
    padding: 80px 0 30px;
    margin-top: 100px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 50px;
}

.footer-col h4 {
    color: white;
    font-size: 1.2rem;
    margin-bottom: 20px;
}

.footer-col p {
    margin-bottom: 15px;
    font-size: 0.95rem;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #cbdbe0;
    text-decoration: none;
    transition: 0.3s;
}

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

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

.social-links a {
    color: white;
    font-size: 1.2rem;
    background: rgba(255,255,255,0.1);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
}

.social-links a:hover {
    background: var(--secondary-color);
}

@media (max-width: 992px) {
    .hero h1 { font-size: 2.8rem; }
    .two-col, .enroll-split { grid-template-columns: 1fr; gap: 40px; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .hero h1 { font-size: 2.2rem; }
    .nav-links { display: none; }
    #enroll { padding: 40px; }

    /* ── Logo mobile fix ── */
    .logo h1 {
        font-size: 1.2rem;
        white-space: nowrap;
    }

    .logo span {
        font-size: 0.7rem;
        padding: 3px 7px;
    }

    .logo-tagline {
        font-size: 0.6rem;
    }
}