:root {
  --ink: #1D242B;
  --muted: #4E5965;
  --steel: #12324A;
  --steel-2: #1C4764;
  --ground: #E9ECEE;
  --panel: #FFFFFF;
  --line: #CBD2D8;
  --soft: #DCE3E8;
  --accent: #B45309;
  --accent-dark: #8A3F06;
  --accent-light: #F2B36B;
  --on-dark: #B7C6D2;
  --pad: clamp(16px, 5vw, 24px);
  --safe-b: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: 'IBM Plex Sans Arabic', 'Segoe UI', Tahoma, sans-serif;
  font-size: clamp(16px, 1.05vw + 14px, 17px);
  line-height: 1.8;
  overflow-x: hidden;
  overflow-wrap: break-word;
}

img { max-width: 100%; height: auto; display: block; }

h1, h2, h3 {
  font-family: 'Noto Kufi Arabic', 'Segoe UI', Tahoma, sans-serif;
  font-weight: 800;
  line-height: 1.35;
  margin: 0;
  overflow-wrap: break-word;
}

a { color: var(--accent); }
a:hover { color: var(--accent-dark); }

a:focus-visible, button:focus-visible, input:focus-visible,
select:focus-visible, textarea:focus-visible {
  outline: 3px solid var(--accent-light);
  outline-offset: 2px;
}

.wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 var(--pad);
}

/* ---------- Header ---------- */
.site-header { background: var(--steel); color: #fff; position: sticky; top: 0; z-index: 30; }
.site-header .wrap {
  position: relative;
  display: flex; align-items: center; justify-content: space-between;
  gap: clamp(10px, 2vw, 24px);
  padding-top: 12px; padding-bottom: 12px;
}
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; min-width: 0; }
.brand svg { flex: 0 0 auto; width: clamp(34px, 9vw, 44px); height: auto; }
.brand-ar {
  font-family: 'Noto Kufi Arabic', Tahoma, sans-serif; font-weight: 800;
  font-size: clamp(15px, 4.4vw, 20px); line-height: 1.25; display: block;
}
.brand-en {
  font-family: 'Barlow Condensed', sans-serif; font-weight: 500;
  font-size: 13px; letter-spacing: .5px; color: var(--on-dark); display: block;
}
.main-nav { display: flex; align-items: center; gap: clamp(14px, 2.2vw, 26px); }
.main-nav a { color: #fff; text-decoration: none; font-weight: 500; white-space: nowrap; }
.main-nav a:hover { color: var(--accent-light); }
.header-actions { display: flex; align-items: center; gap: 12px; }
.phone-link { color: #fff; text-decoration: none; font-weight: 600; display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.menu-toggle {
  display: none; width: 48px; height: 48px; flex: 0 0 48px;
  border: 1px solid #6E8FA8; border-radius: 6px; background: transparent; cursor: pointer;
}

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 50px; padding: 0 22px; border-radius: 6px;
  font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; border: 0;
  text-align: center;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); color: #fff; }
.btn-ghost { border: 2px solid #6E8FA8; color: #fff; background: transparent; }
.btn-ghost:hover { border-color: var(--accent-light); color: #fff; }
.btn-lg { min-height: 56px; font-size: 18px; padding: 0 28px; }

/* ---------- Hero ---------- */
.hero { background: var(--steel); color: #fff; position: relative; padding: clamp(36px, 7vw, 64px) 0 clamp(64px, 9vw, 96px); }
.hero .wrap { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(28px, 5vw, 56px); align-items: center; }
.hero h1 { font-size: clamp(30px, 8.4vw, 68px); }
.hero .lead { font-size: clamp(17px, 4.4vw, 24px); color: #DDE6ED; margin: 18px 0 0; }
.hero .en-name {
  font-family: 'Barlow Condensed', sans-serif; font-size: clamp(14px, 3.4vw, 18px);
  color: var(--on-dark); margin: 12px 0 0; direction: ltr; text-align: right; line-height: 1.5;
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.hero-facts {
  display: flex; flex-wrap: wrap; gap: 12px 22px; margin: 24px 0 0; padding: 0;
  list-style: none; color: var(--on-dark); font-size: clamp(14px, 3.6vw, 16px);
}
.hero-facts li { display: flex; align-items: center; gap: 8px; }
.hero-art img { border-radius: 10px; width: 100%; }
.edge { position: absolute; bottom: -1px; left: 0; width: 100%; height: clamp(24px, 4vw, 44px); display: block; }

/* ---------- Sections ---------- */
section { scroll-margin-top: 86px; }
.section { padding: clamp(44px, 7vw, 76px) 0; }
.section-title { font-size: clamp(26px, 6.4vw, 42px); color: var(--steel); }
.section-intro { color: #3A444E; max-width: 640px; margin: 16px 0 0; }

.about-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(28px, 5vw, 56px); align-items: start; }
.facts { margin: 0; background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 4px clamp(16px, 4vw, 26px); }
.facts div { display: flex; justify-content: space-between; gap: 16px; padding: 14px 0; border-bottom: 1px solid #E1E6EA; flex-wrap: wrap; }
.facts div:last-child { border-bottom: 0; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; font-weight: 600; }

/* ---------- Products ---------- */
.feature {
  background: var(--panel); border: 1px solid var(--line); border-radius: 10px;
  overflow: hidden; display: grid; grid-template-columns: 1fr 1fr; margin-top: 28px;
}
.feature-body { padding: clamp(22px, 4vw, 40px); }
.feature-body h3 { font-size: clamp(23px, 5.4vw, 30px); }
.feature-body p { color: #3A444E; }
.spec { margin: 18px 0 24px; border-top: 1px solid #E1E6EA; }
.spec div { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid #E1E6EA; flex-wrap: wrap; }
.spec span:first-child { color: var(--muted); }
.spec span:last-child { font-weight: 600; }
.feature figure { margin: 0; background: var(--soft); }
.feature figure img { width: 100%; height: 100%; object-fit: cover; }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(18px, 3vw, 24px); margin-top: 24px; }
.card { border-top: 4px solid var(--steel); padding-top: 18px; }
.card img { border-radius: 8px; width: 100%; }
.card h3 { font-size: clamp(20px, 5vw, 23px); margin: 14px 0 8px; }
.card p { color: #3A444E; margin: 0; }

/* ---------- Process ---------- */
.process { background: var(--panel); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.steps { list-style: none; margin: 30px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; }
.steps li { padding: 0 24px; border-right: 1px solid var(--line); }
.steps li:first-child { padding-right: 0; border-right: 0; }
.steps li:last-child { padding-left: 0; }
.step-num { font-family: 'Barlow Condensed', sans-serif; font-weight: 600; font-size: 46px; line-height: 1; color: var(--accent); display: block; }
.steps h3 { font-size: 21px; margin: 8px 0 6px; }
.steps p { color: var(--muted); margin: 0; font-size: 16px; }

/* ---------- Contact ---------- */
.contact { background: var(--soft); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 56px); align-items: start; margin-top: 26px; }
.contact-list { list-style: none; margin: 0 0 24px; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.contact-list li { display: flex; gap: 12px; align-items: flex-start; }
.contact-list svg { flex: 0 0 24px; margin-top: 4px; }
.contact-list a { color: var(--ink); font-weight: 600; text-decoration: none; }
.contact-list a:hover { color: var(--accent-dark); }
.map { border: 0; width: 100%; height: clamp(200px, 45vw, 300px); border-radius: 10px; background: #C3CED6; }
.map-note {
  background: #C3CED6; border-radius: 10px; height: clamp(160px, 42vw, 300px);
  display: flex; align-items: center; justify-content: center; text-align: center;
  padding: 18px; color: #2F3A44; font-size: clamp(14px, 3.6vw, 16px);
}

form.quote {
  background: var(--panel); border: 1px solid var(--line); border-radius: 10px;
  padding: clamp(20px, 4vw, 32px); display: flex; flex-direction: column; gap: 16px;
}
form.quote h3 { font-size: clamp(22px, 5.4vw, 26px); }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 16px; font-weight: 600; }
.field input, .field select, .field textarea {
  width: 100%; max-width: 100%;
  border: 1px solid #A9B4BE; border-radius: 6px; padding: 12px 14px;
  font: inherit; font-size: 16px; /* 16px يمنع تكبير الشاشة تلقائياً في iOS */
  background: #fff; color: var(--ink);
}
.field input, .field select { min-height: 50px; }
.field textarea { resize: vertical; }
.form-note { font-size: 15px; color: var(--muted); margin: 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--steel); color: var(--on-dark); padding: clamp(28px, 5vw, 40px) 0; }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; align-items: center; }
.site-footer strong { color: #fff; display: block; font-family: 'Noto Kufi Arabic', Tahoma, sans-serif; }
.site-footer a { color: #fff; text-decoration: none; word-break: break-word; }

.whatsapp { background: #1F7A44; color: #fff; }
.whatsapp:hover { background: #176035; color: #fff; }

/* ---------- شريط الاتصال السفلي للجوال ---------- */
.mobile-bar {
  display: none;
  position: fixed; inset-inline: 0; bottom: 0; z-index: 40;
  background: var(--steel); border-top: 1px solid #2F5A78;
  padding: 8px 10px calc(8px + var(--safe-b));
  gap: 8px;
}
.mobile-bar .btn { flex: 1 1 0; min-height: 48px; font-size: 16px; padding: 0 10px; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .steps li { padding: 14px 20px; border-right: 1px solid var(--line); }
  .steps li:nth-child(odd) { padding-right: 0; border-right: 0; }
}

@media (max-width: 900px) {
  .hero .wrap, .about-grid, .contact-grid, .feature { grid-template-columns: 1fr; }
  .hero-art { order: -1; }
  .hero-art img { max-height: 46vh; object-fit: cover; }
  .feature figure img { height: auto; max-height: 300px; }
  .cards { grid-template-columns: 1fr; }
  .card img { max-height: 260px; object-fit: cover; }
}

@media (max-width: 820px) {
  .menu-toggle { display: flex; align-items: center; justify-content: center; }
  .main-nav {
    display: none; position: absolute; top: 100%; right: 0; left: 0;
    background: var(--steel-2); flex-direction: column; align-items: stretch;
    gap: 0; padding: 4px var(--pad) 16px;
    box-shadow: 0 12px 20px rgba(0, 0, 0, .18);
    max-height: calc(100vh - 80px); overflow-y: auto;
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 14px 0; border-bottom: 1px solid #2F5A78; }
  .header-actions .phone-link { display: none; }
  .header-actions .btn { display: none; }
  .mobile-bar { display: flex; }
  body { padding-bottom: calc(66px + var(--safe-b)); }
  .site-footer { padding-bottom: clamp(28px, 5vw, 40px); }
}

@media (max-width: 640px) {
  .steps { grid-template-columns: 1fr; }
  .steps li { padding: 14px 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .steps li:last-child { border-bottom: 0; }
  .hero-cta { flex-direction: column; align-items: stretch; }
  .hero-cta .btn { width: 100%; }
  .feature-body .btn { width: 100%; }
  .facts div, .spec div { flex-direction: column; gap: 2px; }
  .facts dd, .spec span:last-child { color: var(--ink); }
  .site-footer .wrap { flex-direction: column; align-items: flex-start; gap: 8px; }
  .contact-list li { font-size: 16px; }
}

@media (max-width: 380px) {
  .brand-en { display: none; }
  .brand svg { width: 32px; }
  .mobile-bar .btn { font-size: 15px; }
}

/* الشاشات العريضة جداً */
@media (min-width: 1600px) {
  .wrap { max-width: 1360px; }
}

/* الطباعة */
@media print {
  .site-header, .mobile-bar, .hero-cta, form.quote { display: none !important; }
  body { background: #fff; padding-bottom: 0; }
}
