/* ============================================================
   م. حسين مفرح — نظام التصميم الموحد
   الهوية: بنفسجي #4B1B5F · ذهبي #C8A24D · رمادي داكن #222222
   الخطوط: IBM Plex Sans Arabic (عربي) · Inter (لاتيني)
   ============================================================ */

:root {
  --purple: #4b1b5f;
  --purple-deep: #351445;
  --purple-soft: #f4eff7;
  --gold: #c8a24d;
  --gold-soft: #f8f2e3;
  --ink: #222222;
  --muted: #6f6d7a;
  --line: #ece8ef;
  --soft: #faf9fb;
  --paper: #ffffff;
  --radius: 10px;
  --shadow: 0 10px 34px rgba(75, 27, 95, 0.08);
  --font: "IBM Plex Sans Arabic", "Cairo", Tahoma, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--paper);
  line-height: 1.9;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; }
.container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }

/* ---------- الهيدر ---------- */
.site-header {
  min-height: 76px;
  padding: 0 max(28px, calc((100% - 1220px) / 2));
  display: flex;
  align-items: center;
  gap: 26px;
  background: #fff;
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 50;
}
.brand { display: flex; flex-direction: column; line-height: 1.45; min-width: 210px; position: relative; padding-right: 48px; }
.brand-mark {
  position: absolute; right: 0; top: 50%; transform: translateY(-50%);
  color: var(--purple); font-weight: 800; font-size: 24px; letter-spacing: -3px;
  font-family: Inter, var(--font);
}
.brand strong { font-size: 16px; }
.brand small { font-size: 9.5px; font-weight: 600; color: var(--muted); }
.brand small.brand-tag { color: var(--gold); letter-spacing: 2px; }
.site-header nav { display: flex; justify-content: center; gap: 26px; flex: 1; font-size: 13.5px; }
.site-header nav a { padding: 26px 0; position: relative; white-space: nowrap; }
.site-header nav a.active, .site-header nav a:hover { color: var(--purple); font-weight: 700; }
.site-header nav a.active::after {
  content: ""; position: absolute; bottom: 0; right: 0; left: 0; height: 2px; background: var(--purple);
}
.nav-toggle { display: none; background: none; border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; font-size: 18px; color: var(--purple); cursor: pointer; }
.scroll-top { position: fixed; bottom: 22px; left: 22px; z-index: 40; width: 42px; height: 42px; border: 0; border-radius: 50%; background: var(--purple); color: #fff; cursor: pointer; opacity: 0; visibility: hidden; transform: translateY(10px); transition: .2s; box-shadow: var(--shadow); }
.scroll-top.visible { opacity: 1; visibility: visible; transform: none; }
.form-error a { color: var(--purple); font-weight: 700; text-decoration: underline; }

/* ---------- الأزرار ---------- */
.button, .header-button {
  display: inline-block;
  border-radius: 6px;
  padding: 13px 24px;
  font-weight: 700;
  font-size: 13.5px;
  white-space: nowrap;
  font-family: var(--font);
  border: 0;
  cursor: pointer;
  transition: 0.2s;
}
.header-button { background: var(--purple); color: #fff; }
.header-button:hover, .button.primary:hover { background: var(--purple-deep); }
.button.primary { background: var(--purple); color: #fff; }
.button.outline { border: 1px solid var(--purple); color: var(--purple); background: transparent; }
.button.outline:hover { background: var(--purple-soft); }
.button.gold { background: var(--gold); color: #fff; }
.button.light { background: #fff; color: var(--purple); }
.button span { margin-right: 8px; }

/* ---------- الهيرو (الرئيسية) ---------- */
.hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 500px;
  direction: ltr;
  background: linear-gradient(90deg, #fff 0%, #fff 48%, #f3f0f2 100%);
}
.hero-copy { direction: rtl; text-align: right; max-width: 640px; padding: 70px 7% 60px 10%; align-self: center; }
.eyebrow { font-size: 13px; font-weight: 700; color: var(--purple); margin: 0 0 12px; }
.hero h1 { font-size: clamp(36px, 4.2vw, 58px); line-height: 1.35; margin: 8px 0; }
.hero h1 em { font-style: normal; color: var(--purple); }
.hero h2 { font-size: 26px; font-weight: 600; margin: 0 0 16px; }
.hero p { font-size: 15px; line-height: 2.1; color: #444354; max-width: 560px; }
.actions { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.hero-values { display: flex; gap: 0; margin-top: 28px; color: var(--muted); font-size: 12px; }
.hero-values span { padding: 4px 16px; border-left: 1px solid #ddd4e3; }
.hero-values span:last-child { border-left: 0; }
.hero-values span:first-child { padding-right: 0; color: var(--purple); font-weight: 700; }
.hero-photo {
  min-height: 500px; position: relative; display: flex; align-items: flex-end; justify-content: center;
  overflow: hidden; isolation: isolate;
  background: linear-gradient(115deg, #f9f8fa 0%, #ece6ed 55%, #d9cbdc 100%);
}
.hero-photo::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(circle at 78% 25%, #fff 0, #eee8f0 38%, transparent 70%);
  filter: blur(18px);
}
.hero-photo img { height: 100%; width: 86%; object-fit: contain; object-position: center bottom; mix-blend-mode: multiply; display: block; }

/* ---------- ترويسة الصفحات الداخلية ---------- */
.page-hero {
  background: linear-gradient(120deg, var(--purple) 0%, var(--purple-deep) 70%);
  color: #fff;
  padding: 64px 24px 58px;
  text-align: center;
}
.page-hero .eyebrow { color: var(--gold); }
.page-hero h1 { font-size: clamp(30px, 3.6vw, 44px); margin: 6px 0 10px; line-height: 1.4; }
.page-hero p { max-width: 720px; margin: 0 auto; color: #e8e2ee; font-size: 15px; }

/* ---------- الأقسام ---------- */
.section { padding: 72px 0; }
.section.tinted { background: var(--soft); }
.section-title { text-align: center; margin-bottom: 42px; }
.section-title h2 { font-size: clamp(24px, 3vw, 34px); margin: 0 0 10px; }
.section-title h2 em { font-style: normal; color: var(--purple); }
.section-title span { display: inline-block; width: 56px; height: 3px; background: var(--gold); border-radius: 3px; }
.section-title p { color: var(--muted); max-width: 680px; margin: 12px auto 0; font-size: 14.5px; }
.section-more { text-align: center; margin-top: 36px; }

/* ---------- بطاقة التعريف (الرئيسية) ---------- */
.about-card {
  display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 48px;
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 52px; margin: -46px auto 0; max-width: 1120px; position: relative; z-index: 2;
}
.about-copy h2 { font-size: 30px; margin: 4px 0 14px; color: var(--purple); }
.about-copy p { color: #444354; font-size: 14.5px; }
.signature { font-weight: 800; color: var(--gold); font-size: 20px; display: inline-block; margin-top: 8px; }
.values { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; align-content: center; }
.values article { display: flex; gap: 14px; }
.values i {
  font-style: normal; flex: 0 0 46px; height: 46px; border-radius: 12px;
  background: var(--purple-soft); color: var(--purple);
  display: flex; align-items: center; justify-content: center; font-size: 21px;
}
.values h3 { margin: 0 0 4px; font-size: 15.5px; }
.values p { margin: 0; font-size: 13px; color: var(--muted); line-height: 1.8; }

/* ---------- شريط الشعار ---------- */
.statement {
  background: linear-gradient(100deg, var(--purple), var(--purple-deep));
  color: #fff; text-align: center; padding: 58px 24px;
}
.statement blockquote { margin: 0 auto; max-width: 760px; font-size: clamp(20px, 2.6vw, 30px); font-weight: 700; line-height: 1.8; }
.statement blockquote em { font-style: normal; color: var(--gold); }
.statement p { color: #d9cfe2; margin: 14px auto 0; max-width: 640px; font-size: 14px; }

/* ---------- شبكات البطاقات ---------- */
.service-grid, .article-grid, .case-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.service-grid article {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 30px 26px; text-align: center; transition: 0.25s;
}
.service-grid article:hover { box-shadow: var(--shadow); transform: translateY(-4px); border-color: #ddd0e6; }
.service-grid i {
  font-style: normal; display: inline-flex; width: 58px; height: 58px; border-radius: 50%;
  background: var(--purple-soft); color: var(--purple); align-items: center; justify-content: center;
  font-size: 25px; margin-bottom: 14px;
}
.service-grid h3 { margin: 0 0 8px; font-size: 17px; }
.service-grid p { margin: 0 0 14px; font-size: 13.5px; color: var(--muted); }
.service-grid a, .text-link { color: var(--purple); font-weight: 700; font-size: 13px; }

/* بطاقات الخدمات التفصيلية */
.service-detail { text-align: right; display: flex; flex-direction: column; }
.service-detail header { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.service-detail header i { margin: 0; flex: 0 0 48px; height: 48px; font-size: 21px; }
.service-detail h3 { margin: 0; }
.service-detail .aud { color: var(--gold); font-size: 12px; font-weight: 700; margin: 0 0 8px; }
.service-detail ul { margin: 8px 0 0; padding: 0 18px 0 0; font-size: 13px; color: var(--muted); text-align: right; }
.service-detail ul li { margin-bottom: 4px; }
.service-detail .svc-frame { margin-top: auto; padding-top: 14px; font-size: 11.5px; color: var(--muted); border-top: 1px dashed var(--line); }

/* ---------- المقالات ---------- */
.article-grid article { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: 0.25s; display: flex; flex-direction: column; }
.article-grid article:hover { box-shadow: var(--shadow); transform: translateY(-4px); }
.article-grid .article-body { padding: 22px 22px 24px; display: flex; flex-direction: column; gap: 8px; flex: 1; text-align: right; }
.article-grid h3 { margin: 0; font-size: 16px; }
.article-grid p { margin: 0; font-size: 13px; color: var(--muted); flex: 1; }
.article-grid small { color: #9b93a5; font-size: 11.5px; }
.article-image { height: 150px; background: var(--purple-soft); display: flex; align-items: center; justify-content: center; color: var(--purple); font-size: 34px; }
.article-image.alt { background: var(--gold-soft); color: var(--gold); }

/* ---------- المنهجية: الخطوات ---------- */
.method-cycle { display: grid; grid-template-columns: repeat(7, 1fr); gap: 12px; }
.method-cycle > div {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px 14px 16px; text-align: center; position: relative;
}
.method-cycle b {
  display: inline-flex; width: 34px; height: 34px; border-radius: 50%;
  background: var(--purple); color: #fff; align-items: center; justify-content: center;
  font-size: 14px; margin-bottom: 8px; font-family: Inter, var(--font);
}
.method-cycle h3 { font-size: 13.5px; margin: 0 0 4px; }
.method-cycle p { font-size: 11px; color: var(--muted); margin: 0; line-height: 1.7; }

/* ---------- المنهجيات: أكورديون ---------- */
.framework-list details {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  margin-bottom: 14px; overflow: hidden;
}
.framework-list summary {
  list-style: none; cursor: pointer; padding: 20px 24px;
  display: flex; align-items: center; gap: 16px; font-weight: 700; font-size: 15.5px;
}
.framework-list summary::-webkit-details-marker { display: none; }
.framework-list summary .code {
  flex: 0 0 auto; background: var(--purple-soft); color: var(--purple);
  border-radius: 6px; padding: 4px 10px; font-size: 12px; font-weight: 800; font-family: Inter, var(--font);
}
.framework-list summary .chev { margin-right: auto; color: var(--purple); transition: 0.2s; font-size: 13px; }
.framework-list details[open] summary { border-bottom: 1px solid var(--line); background: var(--soft); }
.framework-list details[open] .chev { transform: rotate(180deg); }
.framework-body { padding: 22px 24px 26px; display: grid; grid-template-columns: 1fr 1fr; gap: 26px; }
.framework-body h4 { margin: 0 0 8px; color: var(--purple); font-size: 14px; }
.framework-body p, .framework-body li { font-size: 13.5px; color: #444354; }
.framework-body ul, .framework-body ol { margin: 0; padding: 0 20px 0 0; }
.framework-body li { margin-bottom: 5px; }
.framework-tagline { grid-column: 1 / -1; margin: 0; background: var(--gold-soft); border-radius: 8px; padding: 12px 16px; font-size: 13.5px; color: #6b5420; }

/* ---------- دراسات الحالة ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 36px; }
.filters button {
  border: 1px solid var(--line); background: #fff; border-radius: 30px;
  padding: 8px 18px; font-size: 13px; font-family: var(--font); cursor: pointer; transition: 0.2s;
}
.filters button.active, .filters button:hover { background: var(--purple); color: #fff; border-color: var(--purple); }
.case-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px 24px; display: flex; flex-direction: column; gap: 10px; transition: 0.25s;
}
.case-card:hover { box-shadow: var(--shadow); transform: translateY(-4px); }
.case-card .case-sector { align-self: flex-start; background: var(--purple-soft); color: var(--purple); border-radius: 30px; padding: 3px 14px; font-size: 11.5px; font-weight: 700; }
.case-card h3 { margin: 2px 0 0; font-size: 16.5px; line-height: 1.6; }
.case-card .client { color: var(--gold); font-size: 12px; font-weight: 700; }
.case-card p { margin: 0; font-size: 13px; color: var(--muted); }
.case-card p b { color: var(--ink); }
.case-card .result { background: var(--soft); border-radius: 8px; padding: 10px 14px; font-size: 12.5px; color: #444354; border-right: 3px solid var(--gold); }
.case-note { max-width: 860px; margin: 40px auto 0; text-align: center; font-size: 12.5px; color: #6b5420; background: var(--gold-soft); border-radius: var(--radius); padding: 14px 22px; }

/* ---------- الأدوات المجانية ---------- */
.tools-wrap { max-width: 880px; }
.tool-card {
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  box-shadow: var(--shadow); margin-bottom: 34px; overflow: hidden; scroll-margin-top: 100px;
}
.tool-card > header {
  display: flex; align-items: center; gap: 16px;
  padding: 26px 30px; border-bottom: 1px solid var(--line); background: var(--soft);
}
.tool-card > header i {
  font-style: normal; flex: 0 0 52px; height: 52px; border-radius: 12px;
  background: var(--purple-soft); color: var(--purple);
  display: flex; align-items: center; justify-content: center; font-size: 23px;
}
.tool-card > header h2 { margin: 0; font-size: 19px; }
.tool-card > header p { margin: 2px 0 0; font-size: 13px; color: var(--muted); }
.tool-body { padding: 26px 30px 30px; }

.tool-q { padding: 14px 0; border-bottom: 1px dashed var(--line); }
.tool-q:first-child { padding-top: 0; }
.tool-q p { margin: 0 0 8px; font-size: 14px; font-weight: 600; }
.tool-q p small {
  font-family: Inter, var(--font); font-size: 10.5px; font-weight: 700;
  color: var(--purple); background: var(--purple-soft);
  border-radius: 4px; padding: 2px 7px; margin-right: 6px;
}
.tool-options { display: flex; gap: 20px; flex-wrap: wrap; }
.tool-options label { display: flex; align-items: center; gap: 6px; font-size: 13.5px; color: #444354; cursor: pointer; }
.tool-options input { accent-color: var(--purple); width: 16px; height: 16px; }

.tool-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-bottom: 6px; }
.tool-fields label { display: block; font-size: 13px; font-weight: 700; }
.tool-fields input, .tool-fields select {
  width: 100%; margin-top: 6px; border: 1px solid var(--line); border-radius: 8px;
  padding: 11px 13px; font-family: var(--font); font-size: 13.5px; background: var(--soft); font-weight: 400;
}
.tool-fields input:focus, .tool-fields select:focus { outline: 2px solid var(--purple-soft); border-color: var(--purple); }

.tool-check {
  display: flex; align-items: flex-start; gap: 11px; padding: 12px 0;
  border-bottom: 1px dashed var(--line); font-size: 14px; cursor: pointer;
}
.tool-check input { accent-color: var(--purple); width: 17px; height: 17px; margin-top: 4px; flex: 0 0 auto; }
.tool-check input:checked + span { color: var(--muted); text-decoration: line-through; }

.tool-body .button { margin-top: 20px; }
.tool-result {
  margin-top: 18px; background: var(--purple-soft); border-right: 3px solid var(--purple);
  border-radius: 8px; padding: 14px 18px; font-size: 13.5px; color: #3b3a47;
}
.tool-result b { color: var(--purple); }
.tool-result.is-good { background: var(--gold-soft); border-right-color: var(--gold); }
.tool-result.is-good b { color: #8a6c1f; }
.tool-result small { display: block; margin-top: 6px; color: var(--muted); font-size: 12px; }

/* ---------- الأسئلة الشائعة ---------- */
.faq-section h2.faq-cat { font-size: 20px; color: var(--purple); margin: 44px 0 16px; }
.faq-list details { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 12px; }
.faq-list summary {
  list-style: none; cursor: pointer; padding: 17px 22px; font-weight: 700; font-size: 14.5px;
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary span { color: var(--purple); font-size: 18px; flex: 0 0 auto; transition: 0.2s; }
.faq-list details[open] summary span { transform: rotate(45deg); }
.faq-list details p { margin: 0; padding: 0 22px 18px; font-size: 13.5px; color: #444354; }
.faq-list details p b { color: var(--purple); }

/* ---------- المقال المميز ---------- */
.featured-article {
  background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow);
  padding: 46px clamp(24px, 5vw, 60px); max-width: 880px; margin: 0 auto;
}
.featured-article .kicker { color: var(--gold); font-weight: 700; font-size: 12.5px; }
.featured-article h2 { font-size: clamp(22px, 3vw, 30px); margin: 8px 0 18px; line-height: 1.6; }
.featured-article h3 { color: var(--purple); font-size: 17px; margin: 26px 0 8px; }
.featured-article p, .featured-article li { font-size: 14.5px; color: #3b3a47; }
.featured-article .exec-summary { background: var(--purple-soft); border-radius: 10px; padding: 18px 22px; font-size: 14px; }
.featured-article .next-step { background: var(--gold-soft); border-radius: 10px; padding: 18px 22px; margin-top: 22px; }

/* ---------- التواصل ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1.2fr; gap: 40px; align-items: start; }
.contact-info h2 { margin-top: 0; }
.contact-info > p { color: #444354; font-size: 14.5px; }
.contact-channels { display: flex; flex-direction: column; gap: 14px; margin-top: 22px; }
.contact-channels a {
  display: flex; align-items: center; gap: 14px; background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px 20px; font-size: 14px; transition: 0.2s;
}
.contact-channels a:hover { border-color: var(--purple); box-shadow: var(--shadow); }
.contact-channels i { font-style: normal; flex: 0 0 42px; height: 42px; border-radius: 10px; background: var(--purple-soft); color: var(--purple); display: flex; align-items: center; justify-content: center; font-size: 19px; }
.contact-channels b { display: block; font-size: 14px; }
.contact-channels small { color: var(--muted); font-size: 12px; }
.contact-form { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 34px; box-shadow: var(--shadow); }
.contact-form h3 { margin: 0 0 6px; }
.contact-form .hint { font-size: 12.5px; color: var(--muted); margin: 0 0 20px; }
.contact-form label { display: block; font-size: 13px; font-weight: 700; margin: 14px 0 6px; }
.contact-form input, .contact-form select, .contact-form textarea {
  width: 100%; border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px;
  font-family: var(--font); font-size: 14px; background: var(--soft);
}
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus { outline: 2px solid var(--purple-soft); border-color: var(--purple); }
.contact-form button { margin-top: 22px; width: 100%; }

/* ---------- البوب أب: كتيّب الخطوات العشر ---------- */
.lead-modal {
  position: fixed; inset: 0; z-index: 300; background: rgba(26, 10, 34, 0.62);
  display: flex; align-items: center; justify-content: center; padding: 24px;
  animation: hb-fade 0.25s ease;
}
@keyframes hb-fade { from { opacity: 0; } to { opacity: 1; } }
.lead-box {
  position: relative; background: #fff; border-radius: 16px; width: min(480px, 100%);
  padding: 40px 36px 30px; box-shadow: 0 30px 70px rgba(0, 0, 0, 0.35); text-align: center;
  animation: hb-rise 0.3s cubic-bezier(0.2, 0.8, 0.3, 1);
}
@keyframes hb-rise { from { transform: translateY(18px); opacity: 0; } to { transform: none; opacity: 1; } }
.lead-close {
  position: absolute; top: 14px; left: 16px; background: none; border: 0;
  font-size: 17px; color: var(--muted); cursor: pointer; line-height: 1;
}
.lead-close:hover { color: var(--purple); }
.lead-badge {
  display: inline-block; background: var(--gold-soft); color: #8a6c1f;
  border-radius: 20px; padding: 4px 14px; font-size: 11.5px; font-weight: 700; margin-bottom: 12px;
}
.lead-box h2 { margin: 0 0 10px; font-size: 21px; line-height: 1.6; }
.lead-box > p { margin: 0 0 22px; font-size: 13.5px; color: var(--muted); line-height: 1.9; }
.lead-form input {
  width: 100%; border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px;
  font-family: var(--font); font-size: 14px; background: var(--soft); margin-bottom: 10px;
}
.lead-form input:focus { outline: 2px solid var(--purple-soft); border-color: var(--purple); }
.lead-hint { margin: 2px 0 14px; font-size: 11.5px; color: var(--muted); }
.lead-form .button { width: 100%; }
.lead-error {
  margin: 12px 0 0; background: #fdeced; color: #a12631;
  border-radius: 8px; padding: 10px 14px; font-size: 12.5px;
}
.lead-privacy { margin: 16px 0 0; font-size: 11px; color: #9b93a5; line-height: 1.8; }
.lead-success { padding: 16px 0 6px; }
.lead-success span {
  display: inline-flex; width: 54px; height: 54px; border-radius: 50%;
  background: #e6f4ec; color: #1e7a49; align-items: center; justify-content: center;
  font-size: 25px; margin-bottom: 12px;
}
.lead-success h2 { margin: 0 0 8px; font-size: 20px; }
.lead-success p { margin: 0 0 18px; font-size: 13.5px; color: var(--muted); }

/* ---------- السيرة الذاتية ---------- */
.cv-wrap { max-width: 880px; margin: 0 auto; }
.cv-group { margin-bottom: 38px; }
.cv-group h3 {
  display: flex; align-items: center; gap: 11px; font-size: 18px; margin: 0 0 18px;
  padding-bottom: 12px; border-bottom: 2px solid var(--line);
}
.cv-group h3 i {
  font-style: normal; width: 36px; height: 36px; border-radius: 10px;
  background: var(--purple-soft); color: var(--purple);
  display: flex; align-items: center; justify-content: center; font-size: 17px;
}
.cv-items { display: flex; flex-direction: column; gap: 18px; }
.cv-item {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px 24px; position: relative;
}
.cv-period {
  display: inline-block; background: var(--gold-soft); color: #8a6c1f;
  border-radius: 20px; padding: 3px 13px; font-size: 11.5px; font-weight: 700; margin-bottom: 9px;
}
.cv-item h4 { margin: 0 0 4px; font-size: 16px; }
.cv-org { display: block; color: var(--purple); font-size: 13px; font-weight: 700; margin-bottom: 8px; }
.cv-item p { margin: 0; font-size: 13.5px; color: #444354; }
.cv-item ul { margin: 10px 0 0; padding: 0 18px 0 0; font-size: 13px; color: var(--muted); }
.cv-item li { margin-bottom: 5px; }

.cv-tags { display: flex; flex-wrap: wrap; gap: 9px; }
.cv-tags span {
  background: #fff; border: 1px solid var(--line); border-radius: 20px;
  padding: 8px 17px; font-size: 13px; color: #444354;
}
.cv-langs { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.cv-lang {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 20px; display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
}
.cv-lang b { font-size: 14.5px; }
.cv-lang small { color: var(--muted); font-size: 12px; }
.cv-level { display: flex; gap: 5px; margin-right: auto; }
.cv-level i { width: 9px; height: 9px; border-radius: 50%; background: var(--line); }
.cv-level i.on { background: var(--gold); }

@media print {
  .site-header, .footer, .cta, .float-btn, .ai-panel, .lead-modal,
  .page-hero, .section-more, .contact-grid { display: none !important; }
  .cv-wrap { max-width: 100%; }
  .cv-item, .cv-lang, .cv-tags span { border-color: #ccc; box-shadow: none; }
  body { background: #fff; }
}

/* ---------- منتقي مواعيد الحجز ---------- */
.slot-picker {
  margin: 22px 0 4px; padding: 18px; background: var(--soft);
  border: 1px solid var(--line); border-radius: var(--radius);
}
.slot-picker > label { margin: 0 0 4px; }
.slot-optional { font-weight: 400; color: var(--muted); font-size: 11.5px; }
.slot-note { margin: 0 0 14px; font-size: 11.5px; color: var(--muted); }
.slot-days { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 10px; }
.slot-days button {
  flex: 0 0 auto; border: 1px solid var(--line); background: #fff; border-radius: 10px;
  padding: 9px 14px; font-family: var(--font); font-size: 11.5px; cursor: pointer;
  color: var(--muted); line-height: 1.5; text-align: center; transition: 0.15s;
}
.slot-days button b { display: block; font-size: 13px; color: var(--ink); }
.slot-days button.active { background: var(--purple); border-color: var(--purple); color: #fff; }
.slot-days button.active b { color: #fff; }
.slot-times { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.slot-times button {
  border: 1px solid var(--line); background: #fff; border-radius: 8px;
  padding: 8px 15px; font-family: Inter, var(--font); font-size: 13px; cursor: pointer; transition: 0.15s;
}
.slot-times button:hover { border-color: var(--purple); color: var(--purple); }
.slot-times button.active { background: var(--purple); border-color: var(--purple); color: #fff; }
.slot-times .slot-clear { font-family: var(--font); font-size: 12px; color: var(--muted); }

/* ---------- الأيقونات العائمة ---------- */
.float-btn {
  position: fixed; bottom: 26px; z-index: 250;
  width: 56px; height: 56px; border-radius: 50%; border: 0; cursor: pointer;
  display: flex; align-items: center; justify-content: center; color: #fff;
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.24); transition: transform 0.2s, box-shadow 0.2s;
}
.float-btn:hover { transform: translateY(-3px) scale(1.05); box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3); }
.float-whatsapp { right: 24px; background: #25d366; }
.float-ai { left: 24px; background: linear-gradient(140deg, var(--purple), #7a3d94); }
.float-ai.is-open { background: var(--ink); }

.float-tip {
  position: absolute; bottom: 50%; transform: translateY(50%);
  background: var(--ink); color: #fff; font-size: 12px; font-weight: 600;
  padding: 7px 13px; border-radius: 8px; white-space: nowrap;
  opacity: 0; pointer-events: none; transition: opacity 0.2s;
}
.float-whatsapp .float-tip { right: 66px; }
.float-ai .float-tip { left: 66px; }
.float-btn:hover .float-tip { opacity: 1; }

.float-dot {
  position: absolute; top: 3px; left: 3px; width: 13px; height: 13px;
  border-radius: 50%; background: var(--gold); border: 2px solid #fff;
  animation: hb-pulse 2s infinite;
}
@keyframes hb-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.25); opacity: 0.7; }
}

/* ---------- نافذة مساعد حسين الذكي ---------- */
.ai-panel {
  position: fixed; bottom: 94px; left: 24px; z-index: 251;
  width: min(390px, calc(100vw - 32px)); height: min(560px, calc(100vh - 130px));
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  box-shadow: 0 24px 60px rgba(28, 12, 36, 0.28);
  display: flex; flex-direction: column; overflow: hidden;
  animation: hb-rise 0.25s cubic-bezier(0.2, 0.8, 0.3, 1);
}
.ai-panel[hidden] { display: none; }

.ai-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 15px 18px; background: linear-gradient(120deg, var(--purple), var(--purple-deep)); color: #fff;
}
.ai-id { display: flex; align-items: center; gap: 11px; }
.ai-avatar {
  width: 40px; height: 40px; border-radius: 11px; background: rgba(255, 255, 255, 0.16);
  display: flex; align-items: center; justify-content: center;
  font-family: Inter, var(--font); font-weight: 800; font-size: 15px; letter-spacing: -1px;
}
.ai-id b { display: block; font-size: 14.5px; }
.ai-id small { font-size: 11.5px; color: #d9cfe2; }
.ai-close { background: none; border: 0; color: #d9cfe2; font-size: 16px; cursor: pointer; padding: 4px; }
.ai-close:hover { color: #fff; }

.ai-log { flex: 1; overflow-y: auto; padding: 18px; display: flex; flex-direction: column; gap: 12px; background: var(--soft); }
.ai-msg { max-width: 88%; border-radius: 12px; padding: 11px 15px; font-size: 13.5px; line-height: 1.9; }
.ai-msg p { margin: 0 0 8px; }
.ai-msg p:last-child { margin: 0; }
.ai-msg ul, .ai-msg ol { margin: 6px 0; padding: 0 18px 0 0; }
.ai-msg li { margin-bottom: 4px; }
.ai-bot { align-self: flex-start; background: #fff; border: 1px solid var(--line); color: #3b3a47; }
.ai-user { align-self: flex-end; background: var(--purple); color: #fff; }
.ai-bot.is-error { background: #fdeced; border-color: #f6d5d8; color: #a12631; }
.ai-alt { margin-top: 8px !important; font-size: 12.5px; }
.ai-alt a { color: var(--purple); font-weight: 700; }

.ai-typing { display: inline-flex; gap: 4px; padding: 3px 0; }
.ai-typing i { width: 7px; height: 7px; border-radius: 50%; background: #c3bcc9; animation: hb-blink 1.3s infinite; }
.ai-typing i:nth-child(2) { animation-delay: 0.2s; }
.ai-typing i:nth-child(3) { animation-delay: 0.4s; }
@keyframes hb-blink { 0%, 60%, 100% { opacity: 0.35; } 30% { opacity: 1; } }

.ai-suggest { display: flex; flex-wrap: wrap; gap: 7px; padding: 12px 16px 0; background: var(--soft); }
.ai-suggest button {
  border: 1px solid #ddd0e6; background: #fff; color: var(--purple); border-radius: 20px;
  padding: 6px 13px; font-size: 12px; font-family: var(--font); cursor: pointer; transition: 0.15s;
}
.ai-suggest button:hover { background: var(--purple); color: #fff; }

.ai-form { display: flex; gap: 8px; padding: 14px 16px 8px; background: var(--soft); border-top: 1px solid var(--line); }
.ai-form input {
  flex: 1; border: 1px solid var(--line); border-radius: 22px; padding: 11px 16px;
  font-family: var(--font); font-size: 13.5px; background: #fff;
}
.ai-form input:focus { outline: 2px solid var(--purple-soft); border-color: var(--purple); }
.ai-form button {
  width: 42px; height: 42px; border-radius: 50%; border: 0; background: var(--purple);
  color: #fff; font-size: 17px; cursor: pointer; flex: 0 0 auto;
}
.ai-form button:hover { background: var(--purple-deep); }
.ai-note { margin: 0; padding: 0 16px 12px; background: var(--soft); font-size: 10.5px; color: var(--muted); text-align: center; }

@media (max-width: 560px) {
  .float-btn { width: 50px; height: 50px; bottom: 18px; }
  .float-whatsapp { right: 16px; }
  .float-ai { left: 16px; }
  .float-tip { display: none; }
  .ai-panel { left: 16px; right: 16px; width: auto; bottom: 78px; height: min(520px, calc(100vh - 110px)); }
}

/* ---------- رسائل النماذج ---------- */
.form-error {
  margin: 14px 0 0; background: #fdeced; color: #a12631;
  border-radius: 8px; padding: 11px 15px; font-size: 12.5px;
}
.form-success { text-align: center; padding: 22px 0; }
.form-success span {
  display: inline-flex; width: 56px; height: 56px; border-radius: 50%;
  background: #e6f4ec; color: #1e7a49; align-items: center; justify-content: center;
  font-size: 26px; margin-bottom: 14px;
}
.form-success h3 { margin: 0 0 8px; font-size: 20px; }
.form-success p { margin: 0; font-size: 13.5px; color: var(--muted); line-height: 1.9; }
.empty-note { text-align: center; color: var(--muted); font-size: 14px; padding: 30px 0; }

/* ---------- شريط الدعوة ---------- */
.cta {
  background: linear-gradient(100deg, var(--purple), var(--purple-deep));
  color: #fff; border-radius: 16px; margin: 0 auto 80px; max-width: 1120px;
  padding: 52px clamp(24px, 6vw, 70px);
  display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap;
}
.cta h2 { margin: 0 0 8px; font-size: clamp(22px, 3vw, 30px); }
.cta p { margin: 0; color: #d9cfe2; font-size: 14.5px; }

/* ---------- الفوتر ---------- */
.footer {
  background: var(--ink); color: #cfcdd4; padding: 60px max(28px, calc((100% - 1220px) / 2)) 0;
  display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 34px; font-size: 13px;
}
.footer h3 { color: #fff; font-size: 14.5px; margin: 0 0 14px; }
.footer a { display: block; margin-bottom: 9px; color: #b9b6c1; }
.footer a:hover { color: var(--gold); }
.footer-brand strong { color: #fff; font-size: 17px; display: block; }
.footer-brand small { display: block; color: #9b98a3; margin-top: 4px; }
.footer-brand .slogan { color: var(--gold); margin-top: 12px; font-size: 12.5px; }
.social { display: flex; gap: 10px; margin-top: 18px; }
.social a { width: 36px; height: 36px; border: 1px solid #3d3b45; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin: 0; font-size: 14px; }
.social a:hover { background: var(--purple); border-color: var(--purple); color: #fff; }
.copyright { grid-column: 1 / -1; border-top: 1px solid #38363f; margin-top: 44px; padding: 20px 0; text-align: center; color: #8f8c98; font-size: 12px; }

/* ---------- استجابة الشاشات ---------- */
@media (max-width: 1024px) {
  .service-grid, .article-grid, .case-grid { grid-template-columns: repeat(2, 1fr); }
  .method-cycle { grid-template-columns: repeat(4, 1fr); }
  .footer { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 860px) {
  .site-header { flex-wrap: wrap; padding: 12px 20px; gap: 12px; }
  .site-header nav {
    display: none; flex-direction: column; gap: 0; flex-basis: 100%; order: 4;
    border-top: 1px solid var(--line); padding-top: 8px;
  }
  .site-header nav.open { display: flex; }
  .site-header nav a { padding: 12px 0; }
  .site-header nav a.active::after { display: none; }
  .nav-toggle { display: block; margin-right: auto; }
  .header-button { padding: 10px 16px; font-size: 12.5px; }
  .hero { grid-template-columns: 1fr; direction: rtl; }
  .hero-copy { padding: 50px 24px 40px; }
  .hero-photo { min-height: 380px; }
  .about-card { grid-template-columns: 1fr; padding: 34px 26px; gap: 30px; margin-top: 0; border-radius: 0; border-inline: 0; }
  .values { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .framework-body { grid-template-columns: 1fr; }
  .tool-fields { grid-template-columns: 1fr; }
  .tool-card > header { padding: 20px; }
  .tool-body { padding: 20px; }
  .cta { border-radius: 0; text-align: center; justify-content: center; }
}
@media (max-width: 560px) {
  .service-grid, .article-grid, .case-grid { grid-template-columns: 1fr; }
  .method-cycle { grid-template-columns: repeat(2, 1fr); }
  .footer { grid-template-columns: 1fr; }
}
