@font-face {
    font-family: 'TheCamel';
    src: url('../fonts/TheYearofTheCamel-Medium.otf') format('opentype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'TheCamel';
    src: url('../fonts/TheYearofTheCamel-Bold.otf') format('opentype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'TheCamel';
    src: url('../fonts/TheYearofTheCamel-ExtraBold.otf') format('opentype');
    font-weight: 800;
    font-style: normal;
    font-display: swap;
}

:root {
    --primary: #005461;
    --primary-light: #007a8c;
    --primary-dark: #003d47;
    --accent: #fbbf24;
    --accent-light: #fcd34d;
    --secondary: #4facfe;
    --text: #1e293b;
    --text-light: #64748b;
    --text-muted: #94a3b8;
    --bg: #f8fafc;
    --white: #ffffff;
    --card-shadow: 0 4px 24px rgba(0,84,97,0.07);
    --card-shadow-hover: 0 12px 40px rgba(0,84,97,0.13);
    --font: 'TheCamel', 'Cairo', sans-serif;
    --radius: 16px;
    --radius-lg: 24px;
    --transition: 0.35s cubic-bezier(.4,0,.2,1);
}

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

html { scroll-behavior: smooth; }

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    direction: rtl;
    line-height: 1.7;
    overflow-x: hidden;
}

/* ===== Utilities ===== */
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.text-center { text-align: center; }

/* ===== Buttons ===== */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 12px 28px; border-radius: 12px; text-decoration: none;
    font-weight: 700; font-family: var(--font); font-size: 1rem;
    transition: var(--transition); cursor: pointer; border: none;
}
.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: var(--white); box-shadow: 0 4px 16px rgba(0,84,97,0.25);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(0,84,97,0.35); }
.btn-outline {
    border: 2px solid var(--primary); color: var(--primary); background: transparent;
}
.btn-outline:hover { background: var(--primary); color: var(--white); }
.btn-accent {
    background: linear-gradient(135deg, var(--accent), var(--accent-light));
    color: var(--primary-dark); font-weight: 800;
    box-shadow: 0 4px 16px rgba(251,191,36,0.35);
}
.btn-accent:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(251,191,36,0.45); }
.btn-white {
    background: var(--white); color: var(--primary); font-weight: 700;
    box-shadow: 0 4px 16px rgba(0,0,0,0.1);
}
.btn-white:hover { transform: translateY(-2px); box-shadow: 0 8px 28px rgba(0,0,0,0.15); }
.btn-sm { padding: 8px 20px; font-size: 0.9rem; border-radius: 10px; }
.rounded-btn { border-radius: 50px; }

.section-tag {
    display: inline-block; padding: 6px 18px; border-radius: 50px;
    font-size: 0.85rem; font-weight: 700; margin-bottom: 12px;
    background: rgba(0,84,97,0.08); color: var(--primary);
}

/* ===== Header ===== */
.landing-header {
    position: fixed; width: 100%; top: 0; z-index: 1000;
    padding: 16px 0; transition: var(--transition);
}
.landing-header.scrolled {
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 2px 20px rgba(0,0,0,0.06); padding: 10px 0;
}
.header-inner {
    display: flex; justify-content: space-between; align-items: center;
}
.landing-header .container {
    max-width: 100%;
    padding: 0 50px;
}
.logo-container {
    display: flex; align-items: center; gap: 14px; text-decoration: none;
    flex: 1; justify-content: flex-start;
}
.logo-container img { height: 48px; width: auto; object-fit: contain; border-radius: 10px; }
.logo-text { font-weight: 700; font-size: 1.05rem; line-height: 1.3; color: var(--primary); }
.logo-text span { font-size: 0.78rem; color: var(--text-light); font-weight: 400; display: block; }

.main-nav { display: flex; gap: 32px; align-items: center; }
.nav-link {
    text-decoration: none; color: var(--text-light); font-weight: 600;
    font-size: 1.05rem; transition: var(--transition); position: relative;
}
.nav-link::after {
    content: ''; position: absolute; bottom: -4px; right: 0;
    width: 0; height: 2px; background: var(--primary);
    transition: var(--transition); border-radius: 2px;
}
.nav-link:hover, .nav-link.active { color: var(--primary); }
.nav-link:hover::after, .nav-link.active::after { width: 100%; }

.header-actions { display: flex; align-items: center; gap: 16px; flex: 1; justify-content: flex-end; }
.login-link {
    color: var(--primary) !important; text-decoration: none;
    font-weight: 600; font-size: 0.95rem; transition: var(--transition);
}
.login-link:hover { opacity: 0.8; }

/* Mobile menu toggle */
.mobile-toggle {
    display: none; background: none; border: none; font-size: 1.5rem;
    color: var(--primary); cursor: pointer;
}

/* ===== Hero ===== */
.hero-section {
    position: relative; overflow: hidden;
    background: linear-gradient(170deg, #eef6f8 0%, #f0f7fa 30%, #fef9ec 70%, #fff 100%);
    padding-bottom: 50px;
}
.hero-section.static-hero {
    padding: 140px 0 80px; text-align: center;
}

/* Swiper Hero */
.hero-swiper {
    width: 100%;
    height: 600px; /* Default height if not specified */
    position: relative;
    padding-bottom: 60px; /* space for stats overlap */
}
/* Custom Navigation Controls (Bottom Left) */
.hero-nav-controls {
    position: absolute;
    bottom: 70px;
    left: 40px;
    z-index: 10;
    display: flex;
    gap: 12px;
    align-items: center;
}
.hero-nav-btn {
    width: 44px;
    height: 44px;
    border: 1.5px solid #005461;
    border-radius: 12px;
    background: transparent;
    color: #005461;
    opacity: 0.8;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.hero-nav-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    opacity: 1;
    transform: translateY(-3px);
}
.hero-nav-btn:active {
    transform: translateY(0);
}
.hero-nav-btn svg {
    pointer-events: none;
}
.hero-slide {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding-top: 80px;
    overflow: hidden;
}
.hero-bg-icon {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1;
    pointer-events: none;
    user-select: none;
    transition: all 0.5s ease;
}
.hero-bg-icon i {
    display: inline-block;
    transition: all 0.5s ease;
}
.hero-slide-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    z-index: 1;
    transition: opacity 0.3s ease;
}

.hero-slide-bg::after {
    display: none;
}
.hero-slide-content {
    position: relative;
    z-index: 2;
    padding: 0 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center; /* Default center */
    height: 100%;
    width: 100%;
    box-sizing: border-box;
}
.hero-slide-content.content-pos-right {
    align-items: flex-start !important; /* flex-start = RIGHT side in RTL */
    padding-right: 60px;
    padding-left: 20px;
}
.hero-text-box {
    max-width: 850px;
    margin: 0 auto;
    text-align: center;
    transition: all 0.5s ease;
}
/* Content Positioning: push block to the right side */
.content-pos-right .hero-text-box {
    max-width: 850px;
    width: 100%;
    margin: 0 !important;
}
/* Text Alignment within the box */
.text-align-right .hero-text-box {
    text-align: right !important;
}
.content-pos-right .hero-actions {
    justify-content: flex-end !important;
}
.text-align-right .hero-actions {
    justify-content: flex-start !important;
}
.text-align-right .hero-subtitle,
.text-align-right .hero-badge {
    margin-right: 0 !important;
    margin-left: auto !important;
}
.content-pos-right .hero-subtitle,
.content-pos-right .hero-badge {
    margin-left: auto !important;
    margin-right: 0 !important;
}
.hero-slide-content .hero-title, 
.hero-slide-content .hero-subtitle,
.hero-slide-content .hero-badge {
    color: var(--text-color, var(--primary));
}
.hero-slide-content .hero-subtitle {
    color: var(--text-color, var(--text-light));
}
.hero-slide-content .hero-badge {
    color: var(--text-color, var(--primary));
    border: 1px solid var(--text-color, var(--primary));
    background: transparent;
}
.stats-overlap {
    margin-top: -80px;
    margin-bottom: 120px;
    position: relative;
    z-index: 10;
}

.swiper-button-next, .swiper-button-prev {
    color: var(--primary) !important;
}
.swiper-pagination-bullet-active {
    background: var(--primary) !important;
}
.hero-section::before {
    content: ''; position: absolute; top: -120px; left: -120px;
    width: 400px; height: 400px; border-radius: 50%;
    background: radial-gradient(circle, rgba(0,84,97,0.06) 0%, transparent 70%);
    animation: float 8s ease-in-out infinite;
}
.hero-section::after {
    content: ''; position: absolute; bottom: -80px; right: -80px;
    width: 300px; height: 300px; border-radius: 50%;
    background: radial-gradient(circle, rgba(251,191,36,0.08) 0%, transparent 70%);
    animation: float 10s ease-in-out infinite reverse;
}
@keyframes float {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(20px, -20px); }
}
.hero-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: rgba(0,84,97,0.08); color: var(--primary);
    padding: 8px 20px; border-radius: 50px; font-size: 0.9rem;
    font-weight: 600; margin-bottom: 24px;
    animation: fadeInUp 0.6s ease-out;
}
.hero-badge i { font-size: 0.85rem; }
.hero-title {
    font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 800;
    color: var(--primary); line-height: 1.35; margin-bottom: 20px;
    animation: fadeInUp 0.6s ease-out 0.1s both;
}
.hero-title .highlight {
    background: linear-gradient(135deg, var(--accent), #f59e0b);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
}
.hero-subtitle {
    font-size: 1.1rem; color: var(--text-light);
    max-width: 650px; margin: 0 auto 36px; line-height: 1.9;
    animation: fadeInUp 0.6s ease-out 0.2s both;
}
.hero-actions {
    display: flex; gap: 16px; justify-content: center; flex-wrap: wrap;
    margin-bottom: 60px; animation: fadeInUp 0.6s ease-out 0.3s both;
}

/* Stats */
.stats-container {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px; max-width: 900px; margin: 0 auto;
    animation: fadeInUp 0.6s ease-out 0.4s both;
}
.stat-card {
    background: var(--white); padding: 28px 16px; border-radius: var(--radius);
    box-shadow: var(--card-shadow); text-align: center;
    transition: var(--transition); border: 1px solid rgba(0,84,97,0.04);
    position: relative; overflow: hidden;
}
.stat-card::before {
    content: ''; position: absolute; top: 0; right: 0; left: 0; height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    opacity: 0; transition: var(--transition);
}
.stat-card:hover { transform: translateY(-6px); box-shadow: var(--card-shadow-hover); }
.stat-card:hover::before { opacity: 1; }
.stat-icon-wrapper {
    width: 48px; height: 48px; border-radius: 12px; margin: 0 auto 12px;
    display: flex; align-items: center; justify-content: center;
    background: rgba(0,84,97,0.08); color: var(--primary); font-size: 1.3rem;
}
.stat-number { font-size: 1.8rem; font-weight: 800; color: var(--primary); }
.stat-label { color: var(--text-light); font-size: 0.9rem; font-weight: 600; margin-top: 4px; }

/* ===== Features ===== */
.features-section { padding: 90px 0; background: var(--white); }
.section-header { max-width: 600px; margin: 0 auto 50px; }
.section-title {
    font-size: clamp(1.6rem, 3.5vw, 2.2rem); font-weight: 800;
    color: var(--primary); margin-bottom: 12px;
}
.section-desc { color: var(--text-light); font-size: 1.05rem; line-height: 1.8; }

.features-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}
.feature-card {
    background: var(--white); padding: 28px; border-radius: var(--radius);
    border: 1px solid rgba(0,84,97,0.06);
    box-shadow: 0 2px 12px rgba(0,0,0,0.03);
    transition: var(--transition); position: relative; overflow: hidden;
}
.feature-card::after {
    content: ''; position: absolute; bottom: 0; right: 0; left: 0; height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transform: scaleX(0); transition: var(--transition);
}
.feature-card:hover { transform: translateY(-4px); box-shadow: var(--card-shadow-hover); }
.feature-card:hover::after { transform: scaleX(1); }
.feature-icon-box {
    width: 56px; height: 56px; border-radius: 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.4rem; color: var(--white); margin-bottom: 18px;
}
.icon-blue { background: linear-gradient(135deg, var(--primary), var(--primary-light)); }
.icon-yellow { background: linear-gradient(135deg, var(--accent), #f59e0b); }
.feature-title { font-size: 1.15rem; font-weight: 700; color: var(--text); margin-bottom: 8px; }
.feature-desc { font-size: 0.92rem; color: var(--text-light); line-height: 1.7; }

/* ===== Roles ===== */
.roles-section { padding: 90px 0; background: var(--bg); }
.role-card-wrapper { display: flex; flex-direction: column; gap: 20px; margin-top: 10px; }
.role-card {
    border-radius: var(--radius-lg); overflow: hidden; display: flex;
    background: var(--white); box-shadow: var(--card-shadow);
    transition: var(--transition);
}
.role-card:hover { box-shadow: var(--card-shadow-hover); }
.role-card-header {
    width: 260px; min-width: 260px; padding: 36px 28px;
    display: flex; flex-direction: column; justify-content: center;
    align-items: center; text-align: center; color: var(--white); position: relative;
}
.bg-primary { background: linear-gradient(135deg, #005461, #007a8c); }
.bg-admin { background: linear-gradient(135deg, #1a4480, #2563eb); }
.bg-supervisor { background: linear-gradient(135deg, #d97706, #fbbf24); color: #333 !important; }
.bg-teacher { background: linear-gradient(135deg, #0284c7, #4facfe); }
.bg-parent { background: linear-gradient(135deg, #059669, #10b981); }
.bg-receptionist { background: linear-gradient(135deg, #7c3aed, #a78bfa); }

.header-content h3 { margin: 12px 0 4px; font-size: 1.3rem; }
.header-content p { font-size: 0.88rem; opacity: 0.9; }

.role-features {
    flex: 1; padding: 28px 36px;
    display: grid; grid-template-columns: repeat(2, 1fr);
    align-items: center; gap: 16px;
}
.role-feature-item {
    display: flex; align-items: center; gap: 10px;
    font-size: 0.95rem; color: var(--text-light); font-weight: 500;
}
.role-feature-item i { color: var(--primary); font-size: 0.85rem; }

/* ===== CTA / Footer ===== */
.cta-footer {
    background: linear-gradient(160deg, var(--primary-dark), var(--primary), var(--primary-light));
    color: var(--white); padding: 80px 0 28px; position: relative;
    overflow: hidden; text-align: center;
}
.cta-footer::before {
    content: ''; position: absolute; top: -100px; left: 50%;
    transform: translateX(-50%); width: 600px; height: 600px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(251,191,36,0.08) 0%, transparent 70%);
}
.cta-heart {
    background: #ffffff !important;
    width: 90px; height: 90px; border-radius: 22px;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 28px; font-size: 1.8rem;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    border: 1px solid rgba(255,255,255,0.15);
}
.cta-heart img { height: 40px; width: auto; border-radius: 6px; }
.cta-heart i { color: #fbbf24; }
.cta-title {
    font-size: clamp(1.6rem, 4vw, 2.4rem); margin-bottom: 16px; font-weight: 800;
}
.cta-text {
    opacity: 0.85; max-width: 550px; margin: 0 auto 36px;
    font-size: 1.05rem; line-height: 1.8;
}

.footer-links {
    margin-top: 70px; border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 40px; display: flex; justify-content: space-between;
    flex-wrap: wrap; text-align: right; gap: 36px;
}
.footer-col h4 { color: var(--accent); margin-bottom: 16px; font-size: 1.05rem; }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 10px; }
.footer-col a {
    color: rgba(255,255,255,0.75); text-decoration: none;
    transition: var(--transition); font-size: 0.92rem;
}
.footer-col a:hover { color: var(--white); padding-right: 4px; }
.footer-bottom {
    margin-top: 36px; border-top: 1px solid rgba(255,255,255,0.08);
    padding-top: 20px; display: flex; justify-content: center;
    align-items: center; flex-wrap: wrap; gap: 8px;
    font-size: 0.9rem; opacity: 0.75;
}
.footer-bottom a { color: var(--accent); text-decoration: none; }
.footer-bottom img { height: 50px; width: auto; transform: translateY(14px); }

/* ===== Animations ===== */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(24px); }
    to { opacity: 1; transform: translateY(0); }
}
.reveal {
    opacity: 0; transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ===== Dropdown (logged in user) ===== */
.user-dropdown { position: relative; }
.user-btn {
    display: flex; align-items: center; gap: 10px;
    background: transparent; border: 1px solid rgba(0,84,97,0.12);
    padding: 5px 14px 5px 5px; border-radius: 50px;
    cursor: pointer; font-family: var(--font); font-size: 0.92rem;
    color: var(--text); transition: var(--transition);
}
.user-btn:hover { background: rgba(0,84,97,0.04); }
.user-avatar {
    width: 32px; height: 32px; background: var(--primary); color: var(--white);
    border-radius: 50%; display: flex; align-items: center;
    justify-content: center; font-size: 0.85rem;
}
.user-name { font-weight: 700; color: var(--primary); }
.dropdown-menu {
    position: absolute; top: calc(100% + 8px); left: 0;
    min-width: 210px; background: var(--white);
    box-shadow: 0 10px 40px rgba(0,0,0,0.12); border-radius: var(--radius);
    opacity: 0; visibility: hidden; transform: translateY(8px);
    transition: var(--transition); z-index: 1000;
    text-align: right; overflow: hidden;
    border: 1px solid rgba(0,0,0,0.05);
}
.dropdown-menu.show { opacity: 1; visibility: visible; transform: translateY(0); }
.dropdown-header {
    padding: 14px 18px; background: var(--bg);
    border-bottom: 1px solid rgba(0,0,0,0.05);
}
.dropdown-header strong { display: block; color: var(--primary); font-size: 0.95rem; }
.dropdown-header small { color: var(--text-light); font-size: 0.82rem; }
.dropdown-item {
    display: flex; align-items: center; gap: 10px;
    padding: 11px 18px; text-decoration: none; color: var(--text-light);
    transition: var(--transition); font-size: 0.92rem; font-weight: 600;
}
.dropdown-item:hover { background: rgba(0,84,97,0.04); color: var(--primary); padding-right: 22px; }
.dropdown-item i { width: 18px; text-align: center; color: var(--primary); }
.dropdown-item.text-danger:hover { background: #fff5f5; color: #dc3545; }
.dropdown-item.text-danger i { color: #dc3545; }

/* ===== Responsive ===== */
@media (max-width: 900px) {
    .role-card { flex-direction: column; }
    .role-card-header { width: 100%; min-width: auto; padding: 28px; }
    .role-features { grid-template-columns: 1fr; padding: 24px; }
}
@media (max-width: 768px) {
    .landing-header .container { padding: 0 20px; }
    .main-nav { display: none; }
    .mobile-toggle { display: block; }
    .main-nav.open {
        display: flex; flex-direction: column;
        position: absolute; top: 100%; right: 0; left: 0;
        background: var(--white); box-shadow: 0 10px 30px rgba(0,0,0,0.1);
        padding: 20px; gap: 16px; border-radius: 0 0 var(--radius) var(--radius);
    }
    .header-inner { position: relative; }
    .hero-section { padding: 120px 0 60px; }
    .stats-container { grid-template-columns: repeat(2, 1fr); }
    .footer-links { flex-direction: column; text-align: center; }
    .footer-col { width: 100%; }
}
@media (max-width: 480px) {
    .stats-container { grid-template-columns: 1fr; }
    .hero-actions { flex-direction: column; align-items: center; }
}
