/* Shams Djazair — C&I landing pages — shared base (tokens, reset, shared components).
   Mobile first. Breakpoints: sm = 640px, lg = 1000px. */

@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url(../fonts/Montserrat-latin.woff2) format('woff2');
}
/* Arabic text: Cairo. The browser downloads it only when the page shows Arabic letters. */
@font-face {
  font-family: 'Cairo';
  font-style: normal;
  font-weight: 200 1000;
  font-display: swap;
  src: url(../fonts/Cairo-arabic.woff2) format('woff2');
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-088E, U+0890-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}

:root {
  /* color */
  --color-ink: #111111;
  --color-text: #333333;
  --color-text-muted: #555555;
  --color-border-control: #8A8A8A;
  --color-border: #C9C9C9;
  --color-hairline: #E2E2E2;
  --color-surface: #FFFFFF;
  --color-surface-neutral: #F1F1F1;
  --color-paper: #F4F5F3;
  --color-navy: #192E45;
  --color-navy-050: #EEF2F6;
  --color-navy-075: #EBF0F5;
  --color-navy-100: #E8EEF4;
  --color-navy-300: #B9C6D4;
  --color-on-navy-muted: #DCE6F0;
  --color-accent: #E0FF04;
  --color-success: #1B7F4F;
  --color-disabled-bg: #F1F1F1;
  --color-disabled-border: #C9C9C9;
  --color-disabled-text: #555555;
  --color-error: #B42318;
  /* font */
  --font-family: Montserrat, Cairo, system-ui, -apple-system, 'Segoe UI', sans-serif;
  /* radius */
  --radius-tile-c: 8px;
  --radius-control: 12px;
  --radius-option: 14px;
  --radius-map: 16px;
  --radius-card-project: 18px;
  --radius-card: 20px;
  --radius-panel: 24px;
  --radius-pill: 999px;
  /* shadow */
  --shadow-card: 0 1px 2px rgba(17,17,17,0.06), 0 6px 20px rgba(17,17,17,0.08);
  --shadow-card-soft: 0 1px 2px rgba(17,17,17,0.06);
  --shadow-form-card: 0 24px 60px rgba(17,17,17,0.14);
  --shadow-bar: 0 -6px 20px rgba(17,17,17,0.08);
  --shadow-selected: inset 0 0 0 2px #192E45;
  --shadow-accent-outline: inset 0 0 0 1.5px #111111;
  /* motion */
  --motion-ease: cubic-bezier(.22,.8,.24,1);
  --motion-step-in: 450ms;
  --motion-reveal: 400ms;
  --motion-progress: 500ms;
  --motion-marquee: 24s;
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-family);
  font-size: 15px;
  line-height: 1.45;
  color: var(--color-ink);
  background: var(--color-surface);
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}
h1, h2, h3, h4, p, ul, ol, figure, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
a { color: var(--color-ink); }
a:hover { color: var(--color-navy); }
[hidden] { display: none !important; }
:where(button, a, input, select, [tabindex]):focus-visible { outline: 2px solid var(--color-navy); outline-offset: 3px; }
:where(h1, h2, h3)[tabindex="-1"]:focus { outline: none; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* ---------- motion ---------- */
@keyframes step-in { from { opacity: 0; transform: translateX(28px); } to { opacity: 1; transform: none; } }
@keyframes step-in-back { from { opacity: 0; transform: translateX(-28px); } to { opacity: 1; transform: none; } }
@keyframes reveal-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes logo-marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes sd-spin { to { transform: rotate(360deg); } }
.step-in { animation: step-in var(--motion-step-in) var(--motion-ease) both; }
.step-in-back { animation: step-in-back var(--motion-step-in) var(--motion-ease) both; }
.reveal { animation: reveal-in var(--motion-reveal) var(--motion-ease) both; }

/* Marquee: the track holds the items twice. Put the gap on each item (margin-right), not on the track. */
.marquee { overflow: hidden; }
.logo-track { display: flex; align-items: center; width: max-content; animation: logo-marquee var(--motion-marquee) linear infinite; }
.logo-track > * { flex: none; }

@media (prefers-reduced-motion: reduce) {
  .step-in, .step-in-back, .reveal, .logo-track { animation: none !important; }
  .marquee { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  html { scroll-behavior: auto !important; }
}

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 28px;
  border: 1px solid var(--color-ink); border-radius: var(--radius-pill);
  background: var(--color-surface); color: var(--color-ink);
  font-size: 15px; font-weight: 700; line-height: 1.2; text-decoration: none; text-align: center;
  cursor: pointer;
  transition: transform 120ms ease-out;
}
.btn:hover { color: var(--color-ink); }
.btn svg { flex: none; }
.btn--primary { background: var(--color-accent); border-width: 1.5px; }
.btn--dark { min-height: 60px; background: var(--color-ink); color: #fff; }
.btn--dark:hover { color: #fff; }
.btn--sm { min-height: 48px; padding: 0 22px; font-size: 14px; }
.btn--block { display: flex; width: 100%; }
@media (hover: hover) { .btn:not(:disabled):not([aria-disabled="true"]):hover { transform: translateY(-1px); } }
.btn:disabled, .btn[aria-disabled="true"] {
  background: var(--color-disabled-bg); border: 1.5px solid var(--color-disabled-border);
  color: var(--color-disabled-text); cursor: not-allowed;
}
.btn .spinner { display: none; }
.btn[aria-busy="true"] { cursor: progress; }
.btn[aria-busy="true"] .btn-arrow { display: none; }
.btn[aria-busy="true"] .spinner { display: inline-block; }
.spinner {
  width: 18px; height: 18px; flex: none;
  border: 2.5px solid rgba(17,17,17,.25); border-top-color: var(--color-ink); border-radius: 50%;
  animation: sd-spin .8s linear infinite;
}

/* ---------- options (choice buttons). Size and radius are set by each page. ---------- */
.opt {
  display: flex; align-items: center; gap: 12px; width: 100%;
  border: 1px solid var(--color-border-control); background: var(--color-surface); color: var(--color-ink);
  font-weight: 600; text-align: left; line-height: 1.25;
  transition: border-color 120ms ease-out, background-color 120ms ease-out;
}
@media (hover: hover) { .opt:hover { border-color: var(--color-navy); background: var(--color-navy-050); } }
.opt[aria-pressed="true"] {
  background: var(--color-navy-100); border-color: var(--color-navy);
  box-shadow: var(--shadow-selected); font-weight: 700;
}
.opt--unsure { border-style: dashed; color: var(--color-text-muted); }

/* ---------- form fields ---------- */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field-label { font-size: 14px; font-weight: 600; color: var(--color-ink); }
.field-label .opt-note { font-weight: 400; color: var(--color-text-muted); }
.input, .select {
  width: 100%; height: 52px; padding: 0 16px;
  border: 1px solid var(--color-border-control); border-radius: var(--radius-control);
  background: var(--color-surface); color: var(--color-ink);
  font-size: 16px; /* 16px stops iOS zoom on focus */ font-weight: 600;
}
@media (min-width: 640px) { .input, .select { font-size: 15px; } }
.input::placeholder { color: #767676; font-weight: 400; }
.select {
  appearance: none; -webkit-appearance: none; padding-right: 44px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23111111' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
.input[aria-invalid="true"], .select[aria-invalid="true"] { border-color: var(--color-error); box-shadow: inset 0 0 0 1px var(--color-error); }
.field-error { font-size: 13px; line-height: 1.35; color: var(--color-error); font-weight: 500; }

.check { display: flex; align-items: flex-start; gap: 12px; font-size: 13px; line-height: 1.45; color: var(--color-text); cursor: pointer; }
.check input[type="checkbox"] {
  appearance: none; -webkit-appearance: none; flex: none; width: 24px; height: 24px; margin: 0;
  border: 1px solid var(--color-border-control); border-radius: 6px; background: #fff; cursor: pointer;
}
.check input[type="checkbox"]:checked {
  background: var(--color-navy) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12.5 4.5 4.5L19 7.5'/%3E%3C/svg%3E") center/16px no-repeat;
  border-color: var(--color-navy);
}
.check input[type="checkbox"][aria-invalid="true"] { border-color: var(--color-error); box-shadow: inset 0 0 0 1px var(--color-error); }

/* honeypot: never shown. No off-screen offset: a far-left box makes a right-to-left page scroll sideways. */
.hp-field {
  position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden;
  clip: rect(0, 0, 0, 0); clip-path: inset(50%); white-space: nowrap; opacity: 0; pointer-events: none;
}

/* network-error box (inserted by core.js) */
.form-error {
  display: flex; flex-direction: column; gap: 12px; padding: 14px 16px;
  border: 1px solid var(--color-error); border-radius: var(--radius-control);
  background: #FEF3F2; color: var(--color-ink); font-size: 14px;
}
.form-error strong { color: var(--color-error); }
.form-error-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.form-error-actions .btn { min-height: 44px; padding: 0 18px; font-size: 14px; }

/* ---------- small shared pieces ---------- */
.tag {
  display: inline-flex; align-items: center; min-height: 22px; padding: 2px 10px;
  border-radius: var(--radius-pill); background: var(--color-accent); color: var(--color-ink);
  font-size: 11px; font-weight: 700; line-height: 1.3;
}
.tag--outline { border: 1.5px solid var(--color-ink); }
.yes-mark, .no-mark { display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 50%; flex: none; }
.yes-mark { background: var(--color-success); color: #fff; }
.no-mark { background: var(--color-hairline); color: var(--color-text-muted); }

/* No JavaScript: show phone + WhatsApp */
.nojs-box {
  margin: 16px; padding: 16px; border: 1px solid var(--color-ink); border-radius: var(--radius-control);
  background: var(--color-accent); font-weight: 600; text-align: center;
}

/* ---------- languages (fr, en, ar) ---------- */
/* English and Arabic: the page stays hidden until core.js has put the translated text in place.
   If the script fails, the page shows after 3 s (in French). */
@keyframes sd-show { to { visibility: visible; } }
html.i18n-pending body { visibility: hidden; animation: sd-show 0s 3s forwards; }

/* language menu (core.js fills every [data-lang-switch]) */
.lang-switch { display: inline-flex; flex: none; }
.lang-select {
  appearance: none; -webkit-appearance: none;
  height: 44px; padding: 0 30px 0 36px; border: 1px solid var(--color-border-control); border-radius: var(--radius-pill);
  background-color: var(--color-surface); color: var(--color-ink); font-size: 13px; font-weight: 700; cursor: pointer;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%23111111' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M3 12h18M12 3c2.800 3 2.800 15 0 18M12 3c-2.800 3-2.800 15 0 18'/%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23111111' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat, no-repeat; background-position: left 12px center, right 11px center;
}
.lang-select:lang(ar) { font-family: Cairo, system-ui, sans-serif; }
@media (max-width: 359px) {
  .lang-select { height: 44px; padding: 0 24px 0 31px; font-size: 12px; background-position: left 9px center, right 7px center; }
}

/* Arabic: a little more line height, no uppercase tracking (Arabic has no capitals and must stay joined) */
html[lang="ar"] body { line-height: 1.6; }
html[lang="ar"] * { letter-spacing: 0 !important; }

/* right-to-left */
[dir="rtl"] .opt { text-align: right; }
[dir="rtl"] .select { padding-right: 16px; padding-left: 44px; background-position: left 14px center; }
[dir="rtl"] .btn-arrow, [dir="rtl"] .flip-rtl { transform: scaleX(-1); }
[dir="rtl"] .step-in { animation-name: step-in-back; }
[dir="rtl"] .step-in-back { animation-name: step-in; }
/* marquees keep moving left-to-right mechanics in every language */
.marquee { direction: ltr; }
/* phone numbers, e-mail addresses and figures stay left-to-right inside Arabic text */
[dir="rtl"] input[type="tel"], [dir="rtl"] input[type="email"] { direction: ltr; text-align: right; }
.ltr { direction: ltr; unicode-bidi: isolate; display: inline-block; }

/* option icons (icons.js) */
.opt-ic { flex: none; color: var(--color-navy); }

/* ---------- area typed by the visitor (m²) ---------- */
.area-field { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.area-row { display: flex; gap: 10px; align-items: stretch; }
.area-input { position: relative; flex: 1 1 auto; min-width: 0; }
.area-input .input { height: 56px; padding-right: 52px; font-size: 18px; font-weight: 700; text-align: left; }
.area-unit { position: absolute; top: 0; right: 16px; height: 56px; display: flex; align-items: center; font-weight: 700; color: var(--color-text-muted); pointer-events: none; }
.area-ok { flex: none; min-height: 56px; padding-left: 20px; padding-right: 20px; }
.area-nsp { min-height: 52px; padding: 10px 16px; border-radius: var(--radius-option); font-size: 15px; justify-content: center; text-align: center; }
