/* =========================================================
   KhedmaDZ — Design System (per Brand Identity Guide)
   Tokens first. Change a brand value here, nowhere else.
   ========================================================= */
:root {
    /* --- Brand colors ---
       PROVISIONAL (not yet approved in the guide): primary, primary-soft, gold, fonts.
       Kept from the existing site; confirm before production. */
    --primary: #0E7490;
    --primary-dark: #0B5F76;
    --primary-soft: #ECFEFF;
    --gold: #D97706;
    --gold-light: #FEF3C7;

    /* --- Approved by the guide --- */
    --bg: #F6F8FC;
    --surface: #FFFFFF;
    --text-dark: #0F172A;
    --border: #E3E7EF;

    /* --- Guide says "dark grey / mid grey" (no hex) --- */
    --text-body: #334155;
    --text-grey: #64748B;

    /* --- Radius --- */
    --radius-pill: 999px;
    --radius-lg: 24px;   /* cards, sheets */
    --radius-md: 18px;   /* inputs */
    --radius-sm: 14px;   /* alerts, icons */

    /* --- Shadows: tint of #0F172A, 3–8% alpha, blur 12–24px --- */
    --shadow-sm: 0 4px 12px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 8px 18px rgba(15, 23, 42, 0.06);
    --shadow-lg: 0 12px 24px rgba(15, 23, 42, 0.08);

    /* --- Controls --- */
    --btn-height: 54px;
    --control-size: 44px;
    --focus-ring: 1.8px solid var(--primary);

    /* --- Derived (from text-dark) for dark surfaces --- */
    --dark-border: rgba(255, 255, 255, 0.10);
    --on-dark-muted: rgba(255, 255, 255, 0.65);

    --transition: all 0.25s ease-in-out;

    /* legacy aliases used by older pages */
    --bg-light: var(--bg);
    --card-bg: var(--surface);
    --muted: var(--text-grey);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
    font-family: 'Cairo', 'Plus Jakarta Sans', sans-serif;
    background: var(--bg);
    color: var(--text-body);
    line-height: 1.7;
    overflow-x: hidden;
}
[dir="ltr"] body { font-family: 'Plus Jakarta Sans', 'Cairo', sans-serif; }

h1, h2, h3, h4 { color: var(--text-dark); line-height: 1.3; }
a { color: var(--primary); }
img { max-width: 100%; }

.container { width: 90%; max-width: 1200px; margin: 0 auto; }

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: var(--btn-height);
    padding: 0 28px;
    font-family: inherit; font-weight: 700; font-size: 16px;
    border-radius: var(--radius-pill);
    text-decoration: none; border: none; cursor: pointer;
    transition: var(--transition);
}
.btn svg { width: 20px; height: 20px; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.btn-gold { background: var(--gold); color: #fff; }
.btn-gold:hover { filter: brightness(0.92); transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.btn-lg { padding: 0 36px; }

.store-btn {
    display: inline-flex; align-items: center; gap: 12px;
    min-height: var(--btn-height);
    background: var(--text-dark); color: #fff;
    padding: 8px 28px; border-radius: var(--radius-pill);
    text-decoration: none; transition: var(--transition);
}
.store-btn i { font-size: 26px; }
.store-btn .btn-text { display: flex; flex-direction: column; text-align: start; line-height: 1.2; }
.store-btn small { font-size: 11px; opacity: .8; }
.store-btn span { font-size: 16px; font-weight: 700; }
.store-btn:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.store-btn.dark { background: #fff; color: var(--text-dark); }

/* circular control (44x44) */
.mobile-toggle, .nav-toggle-label {
    display: none; align-items: center; justify-content: center;
    width: var(--control-size); height: var(--control-size);
    border-radius: 50%; background: var(--surface); border: none;
    box-shadow: var(--shadow-sm); color: var(--text-dark);
    font-size: 24px; cursor: pointer;
}

/* ---------- Inputs ---------- */
input[type="text"], input[type="email"], input[type="search"], textarea, select {
    font-family: inherit; font-size: 16px; color: var(--text-dark);
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius-md); padding: 14px 18px; outline: none;
    transition: var(--transition);
}
input:focus, textarea:focus { border: 1.8px solid var(--primary); }

/* ---------- Navbar (index) ---------- */
.navbar {
    position: sticky; top: 0; z-index: 1000;
    background: rgba(255,255,255,.92); backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border); padding: 12px 0;
}
.nav-container { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.brand-logo img { height: 46px; object-fit: contain; display: block; }
.nav-menu { display: flex; gap: 32px; }
.nav-menu a { text-decoration: none; color: var(--text-grey); font-weight: 600; font-size: 15px; transition: var(--transition); }
.nav-menu a:hover { color: var(--primary); }
.nav-actions { display: flex; align-items: center; gap: 12px; }
.nav-btn { min-height: 44px; padding: 0 22px; font-size: 15px; }

.lang-selector {
    display: flex; align-items: center; gap: 6px;
    background: var(--surface); border: 1px solid var(--border);
    padding: 0 14px; height: 44px; border-radius: var(--radius-pill);
}
.lang-selector select { border: none; padding: 0; background: transparent; font-weight: 700; cursor: pointer; }

/* ---------- Hero (index) ---------- */
.hero-section { padding: 70px 0 50px; }
.hero-container { display: grid; grid-template-columns: 1.2fr .8fr; gap: 40px; align-items: center; }
.badge-tag {
    display: inline-flex; align-items: center; gap: 8px;
    background: var(--primary-soft); color: var(--primary);
    padding: 8px 16px; border-radius: var(--radius-pill);
    font-size: 13px; font-weight: 700; margin-bottom: 20px;
}
.badge-dot { width: 8px; height: 8px; background: var(--primary); border-radius: 50%; }
.hero-content h1 { font-size: 42px; font-weight: 900; line-height: 1.25; margin-bottom: 20px; }
.hero-content p { font-size: 17px; color: var(--text-grey); margin-bottom: 32px; max-width: 540px; }
.hero-stats { display: flex; align-items: center; gap: 24px; margin-top: 36px; padding-top: 24px; border-top: 1px solid var(--border); }
.stat-item { display: flex; flex-direction: column; }
.stat-number { font-size: 28px; font-weight: 800; color: var(--primary); }
.stat-label { font-size: 13px; color: var(--text-grey); font-weight: 600; }
.stat-divider { width: 1px; height: 36px; background: var(--border); }
.hero-visual { display: flex; justify-content: center; }
.phone-mockup {
    width: 270px; height: 550px; background: var(--text-dark);
    border-radius: 44px; padding: 10px; box-shadow: var(--shadow-lg);
}
.phone-screen { width: 100%; height: 100%; background: #000; border-radius: 34px; overflow: hidden; }
.phone-screen img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Sections ---------- */
.section { padding: 70px 0; }
.section-header { text-align: center; max-width: 620px; margin: 0 auto 48px; }
.section-header h2 { font-size: 32px; font-weight: 800; margin-bottom: 12px; }
.section-header p { color: var(--text-grey); font-size: 16px; }

.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 24px; }
.feature-card {
    background: var(--surface); padding: 30px;
    border-radius: var(--radius-lg); border: 1px solid var(--border);
    box-shadow: var(--shadow-sm); transition: var(--transition);
}
.feature-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.feature-icon {
    width: 52px; height: 52px; background: var(--primary-soft); color: var(--primary);
    border-radius: var(--radius-sm); display: flex; align-items: center; justify-content: center;
    font-size: 24px; margin-bottom: 20px;
}
.feature-card h3 { font-size: 18px; font-weight: 700; margin-bottom: 10px; }
.feature-card p { color: var(--text-grey); font-size: 14px; }

.employers-section { background: var(--surface); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.employers-container { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; align-items: center; }
.badge-gold { background: var(--gold-light); color: var(--gold); padding: 6px 14px; border-radius: var(--radius-pill); font-size: 13px; font-weight: 700; }
.employers-content h2 { font-size: 32px; font-weight: 800; margin: 16px 0; }
.employers-content p { color: var(--text-grey); margin-bottom: 24px; }
.emp-list { list-style: none; margin-bottom: 32px; }
.emp-list li { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; font-weight: 600; color: var(--text-dark); }
.emp-list i { color: var(--primary); font-size: 18px; }
.rounded-image { width: 100%; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }

.download-card {
    background: var(--primary); color: #fff;
    padding: 60px 30px; border-radius: var(--radius-lg); text-align: center;
}
.download-content h2 { color: #fff; font-size: 32px; font-weight: 800; margin-bottom: 12px; }
.download-content p { opacity: .9; margin-bottom: 32px; }
.download-buttons { display: flex; justify-content: center; }

/* ---------- Footer (index) ---------- */
.footer { background: var(--text-dark); color: var(--on-dark-muted); padding: 60px 0 30px; }
.footer-container { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 40px; padding-bottom: 40px; border-bottom: 1px solid var(--dark-border); }
.footer-brand p { margin-top: 12px; max-width: 320px; font-size: 14px; }
.footer-links { display: flex; flex-direction: column; gap: 10px; }
.footer-links h4 { color: #fff; margin-bottom: 6px; }
.footer-links a { color: var(--on-dark-muted); text-decoration: none; font-size: 14px; }
.footer-links a:hover { color: #fff; }
.footer-copyright { width: 100%; text-align: center; margin-top: 10px; font-size: 13px; }

/* =========================================================
   Inner pages (about / blog / articles / privacy / terms)
   ========================================================= */
.site-header {
    position: sticky; top: 0; z-index: 1000;
    background: rgba(255,255,255,.92); backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 0; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand .logo { height: 40px !important; width: auto !important; max-width: 150px; object-fit: contain; }
.brand-text .title { font-weight: 900; font-size: 18px; color: var(--text-dark); line-height: 1.2; }
.brand-text .tag { font-size: 11px; color: var(--text-grey); direction: ltr; }
.main-nav ul { list-style: none; display: flex; gap: 26px; }
.main-nav a, .main-nav-mobile a { text-decoration: none; color: var(--text-grey); font-weight: 600; font-size: 15px; transition: var(--transition); }
.main-nav a:hover, .main-nav-mobile a:hover { color: var(--primary); }
.header-actions { display: flex; align-items: center; gap: 12px; }
.header-actions .btn { min-height: 44px; padding: 0 22px; font-size: 15px; }

.lang-switch { display: inline-flex; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-pill); padding: 3px; }
.lang-switch a { padding: 6px 12px; border-radius: var(--radius-pill); font-size: 12px; font-weight: 800; text-decoration: none; color: var(--text-grey); }
.lang-switch a.active { background: var(--primary); color: #fff; }

.nav-toggle { display: none; }
.nav-toggle-label span { display: block; width: 18px; height: 2px; background: var(--text-dark); border-radius: 2px; }
.nav-toggle-label { flex-direction: column; gap: 4px; }
.main-nav-mobile { display: none; flex-direction: column; gap: 4px; padding: 12px 5% 20px; background: var(--surface); border-top: 1px solid var(--border); }
.main-nav-mobile a { padding: 10px 4px; }
.nav-toggle:checked ~ .nav-toggle-label + * { }

.page-hero { position: relative; overflow: hidden; background: var(--surface); border-bottom: 1px solid var(--border); }
.aurora { position: absolute; inset: 0; pointer-events: none; }
.aurora span { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .5; }
.aurora .a1 { width: 320px; height: 320px; background: var(--primary-soft); top: -120px; inset-inline-start: -60px; }
.aurora .a2 { width: 280px; height: 280px; background: var(--gold-light); bottom: -120px; inset-inline-end: -40px; }
.page-hero h1 { color: var(--text-dark); }

.badge { display: inline-block; padding: 6px 16px; border-radius: var(--radius-pill); font-size: 13px; font-weight: 700; margin-bottom: 18px; }
.badge-outline { background: var(--primary-soft); color: var(--primary); border: 1px solid var(--border); }

.article-page { max-width: 820px; padding-top: 48px; padding-bottom: 64px; }
.article-page h2 { font-size: 26px; font-weight: 900; margin: 36px 0 14px; }
.article-page h3 { font-size: 19px; font-weight: 800; margin: 28px 0 10px; }
.article-page p { margin-bottom: 14px; color: var(--text-body); }
.article-page ul, .article-page ol { margin: 0 0 16px; padding-inline-start: 24px; }
.article-page li { margin-bottom: 8px; }
.back-link { display: inline-block; margin-bottom: 20px; font-weight: 700; text-decoration: none; color: var(--primary); }

.about-card, .about-feature, .about-contact, .blog-card {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius-lg); box-shadow: var(--shadow-sm);
}
.about-card { display: flex; gap: 20px; padding: 28px; align-items: flex-start; }
.about-card-icon, .about-feature-icon, .blog-card-icon {
    flex: none; width: 52px; height: 52px; border-radius: var(--radius-sm);
    display: flex; align-items: center; justify-content: center; font-size: 24px; background: var(--primary-soft);
}
.icon-yellow { background: var(--gold-light); }
.icon-blue { background: var(--primary-soft); }
.about-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
@media (max-width: 560px) { .about-grid { grid-template-columns: 1fr; } }
.about-feature { padding: 24px; }
.about-card > div:last-child { flex: 1; min-width: 0; }
.about-card h2 { margin-top: 0; }
.about-feature-icon { margin-bottom: 14px; }
.about-feature h3 { margin: 0 0 8px; font-size: 18px; }
.about-feature p { margin: 0; color: var(--text-grey); font-size: 14px; }

.check-list { list-style: none; padding: 0 !important; }
.check-list li { position: relative; padding-inline-start: 32px; }
.check-list li::before {
    content: "✓"; position: absolute; inset-inline-start: 0; top: 2px;
    width: 22px; height: 22px; border-radius: 50%; background: var(--primary-soft); color: var(--primary);
    font-size: 13px; font-weight: 900; display: flex; align-items: center; justify-content: center;
}

.about-contact { padding: 32px; margin-top: 40px; text-align: center; }
.about-contact h2 { margin-top: 0; }
.contact-links { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 18px; }
.contact-link {
    display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 20px;
    background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius-pill);
    text-decoration: none; font-weight: 700; color: var(--text-dark); direction: ltr;
}

.cta-band { background: var(--primary); color: #fff; border-radius: var(--radius-lg); padding: 44px 28px; text-align: center; }
.cta-band h2 { color: #fff; margin: 0 0 8px; }
.cta-band p { color: rgba(255,255,255,.9); }
.cta-band .btn-primary { background: #fff; color: var(--primary); margin-top: 14px; }

.blog-cards { display: grid; gap: 20px; }
.blog-card { display: flex; gap: 20px; padding: 26px; text-decoration: none; transition: var(--transition); }
.blog-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.blog-card h2 { font-size: 20px; margin: 8px 0; }
.blog-card p { color: var(--text-grey); margin-bottom: 10px; font-size: 15px; }
.blog-tag { display: inline-block; background: var(--primary-soft); color: var(--primary); padding: 4px 12px; border-radius: var(--radius-pill); font-size: 12px; font-weight: 700; }
.blog-read-more { color: var(--primary); font-weight: 800; font-size: 14px; }

.article-cta { background: var(--primary-soft); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 28px; margin-top: 40px; display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; }

.site-footer { background: var(--text-dark); color: var(--on-dark-muted); padding: 56px 0 24px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 36px; padding-bottom: 36px; border-bottom: 1px solid var(--dark-border); }
.site-footer .brand-text .title { color: #fff; }
.site-footer .brand .logo { background: #fff; border-radius: var(--radius-sm); padding: 4px 8px; height: 36px !important; }
.footer-col h4 { color: #fff; margin-bottom: 12px; font-size: 16px; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 8px; }
.footer-col a { color: var(--on-dark-muted); text-decoration: none; font-size: 14px; }
.footer-col a:hover { color: #fff; }
.footer-col p { font-size: 14px; margin: 12px 0; max-width: 320px; }
.social-row { display: flex; gap: 10px; }
.social-row a { width: var(--control-size); height: var(--control-size); border-radius: 50%; background: rgba(255,255,255,.08); display: flex; align-items: center; justify-content: center; font-size: 18px; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding-top: 22px; font-size: 13px; }

/* ---------- Reveal on scroll ---------- */
[data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
[data-reveal="scale"] { transform: scale(.97); }
[data-reveal].in-view { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { [data-reveal] { opacity: 1; transform: none; transition: none; } }

/* ---------- Responsive ---------- */
@media (max-width: 992px) {
    .hero-container, .employers-container { grid-template-columns: 1fr; text-align: center; }
    .hero-content p { margin: 0 auto 32px; }
    .hero-stats { justify-content: center; }
    ..hero-cta { display: flex; justify-content: center; }
    .nav-menu {
        display: none; position: absolute; top: 100%; left: 0; right: 0;
        background: var(--surface); flex-direction: column; padding: 20px;
        box-shadow: var(--shadow-md); border-bottom: 1px solid var(--border);
    }
    .nav-menu.active { display: flex; }
    .mobile-toggle { display: flex; }
    .hero-content h1 { font-size: 32px; }

    .main-nav { display: none; }
    .nav-toggle-label { display: flex; }
    .nav-toggle:checked ~ .nav-toggle-label { background: var(--primary-soft); }
    .site-header:has(.nav-toggle:checked) .main-nav-mobile { display: flex; }
    .header-actions .btn { display: none; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
    .footer-grid { grid-template-columns: 1fr; }
    .about-card, .blog-card { flex-direction: column; }
    .nav-btn { display: none; }
}
