@import url("https://fonts.googleapis.com/css2?family=Tajawal:wght@400;500;600;700&display=swap");

@font-face {
  font-family: "Cinzel";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("https://img1.wsimg.com/gfonts/s/cinzel/v26/8vIU7ww63mVu7gtR-kwKxNvkNOjw-tbnfY3lDQ.woff2") format("woff2");
}

:root {
  --brand-green: #006400;
  --text-color: #000000;
  --muted-text: #595959;
  --page-width: 1160px;
  --body-font: "Quicksand", sans-serif;
  --heading-font: "Cinzel", Georgia, serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  color: var(--text-color);
  background: #ffffff;
  font-family: var(--body-font);
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

/* Quicksand and Cinzel do not include Arabic glyphs. Keep Arabic typography
   deliberate and visually compatible instead of falling back to a system font. */
html[lang="ar"] body,
html[lang="ar"] button,
html[lang="ar"] input,
html[lang="ar"] select,
html[lang="ar"] textarea {
  font-family: "Tajawal", "Quicksand", sans-serif;
}

html[lang="ar"] h1,
html[lang="ar"] h2,
html[lang="ar"] h3,
html[lang="ar"] h4,
html[lang="ar"] h5,
html[lang="ar"] h6 {
  font-family: "Tajawal", "Quicksand", sans-serif;
}

/* Components on the home page declare Quicksand individually. Apply the
   Arabic family directly to the entire visible page at every breakpoint. */
html[lang="ar"] .home-page main,
html[lang="ar"] .home-page main *,
html[lang="ar"] .home-page site-footer,
html[lang="ar"] .home-page site-footer * {
  font-family: "Tajawal", "Quicksand", sans-serif !important;
}

/* Language codes are shared UI labels, so retain the same Latin font in the
   language picker for AR, FR and EN. */
html[lang="ar"] site-toolbar .language-selector,
html[lang="ar"] site-toolbar .language-selector * {
  font-family: "Quicksand", sans-serif;
}

html[lang="ar"] .site-navigation-drawer,
html[lang="ar"] .site-navigation-drawer * {
  font-family: "Tajawal", "Quicksand", sans-serif;
}

a {
  color: inherit;
}

img,
svg {
  display: block;
}

.skip-link {
  position: fixed;
  z-index: 2000;
  top: 8px;
  left: 8px;
  padding: 8px 14px;
  color: #ffffff;
  background: var(--brand-green);
  transform: translateY(-150%);
}

.skip-link:focus {
  transform: translateY(0);
}

.services-section,
.mission-statement,
.insights-section,
.experience-strip {
  width: min(100%, var(--page-width));
  margin: 0 auto;
  background: #ffffff;
}

.services-section {
  height: 512px;
  padding: 56px 24px;
}

.services-grid {
  width: 88%;
  height: 400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 48px;
}

.service-card {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 32px;
  color: #ffffff;
  background: #185127;
  border-radius: 12px;
  font-family: var(--body-font);
  font-size: 32px;
  line-height: 32px;
  font-weight: 400;
  text-align: center;
  text-decoration: none;
  overflow: hidden;
  box-shadow: 0 5px 14px rgba(24, 81, 39, 0.14);
  transform: translateY(0) scale(1);
  transition: transform .35s ease, box-shadow .35s ease, filter .35s ease;
}

.service-card {
  border: 2px solid rgba(245, 249, 235, 0.95);
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 77, 31, 0.25), 0 0 0 1px rgba(189, 210, 157, 0.35);
}

.service-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: #185127;
  transform: scale(1);
  backface-visibility: hidden;
  transition: transform 0.3s ease;
}

.service-card::after {
  content: "";
  position: absolute;
  z-index: 2;
  top: -35%;
  bottom: -35%;
  left: -45%;
  width: 28%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transform: translateX(-180%) skewX(-18deg);
  transition: transform .65s ease;
  pointer-events: none;
}

.service-card-content {
  position: absolute;
  z-index: 1;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 32px;
  background: #185127;
  transform: scale(1.05);
  backface-visibility: hidden;
  transition: transform 0.5s ease, background-color 0.5s ease, text-shadow 0.5s ease;
}

.service-card,
.service-card::before,
.service-card .service-card-content {
  background: linear-gradient(180deg, #006d2c 0%, #004d1f 100%);
}

.mission-statement {
  min-height: 148px;
  display: grid;
  place-items: center;
  padding: 56px 24px;
  color: var(--muted-text);
  text-align: center;
}

.mission-statement p {
  margin: 0;
  font-size: 20px;
  line-height: 1.8;
}

.insights-section {
  min-height: 168px;
  display: grid;
  place-items: center;
  padding: 56px 24px;
}

.insights-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 144.64px;
  min-height: 70px;
  padding: 8px 32px;
  color: #006d2c;
  background: #ffffff;
  border: 2px solid #006d2c;
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 77, 31, 0.25), 0 0 0 1px rgba(189, 210, 157, 0.35);
  font-family: var(--body-font);
  font-size: 22px;
  font-weight: 400;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  text-transform: uppercase;
  transition: filter .2s ease, transform .2s ease, box-shadow .2s ease;
}

.insights-link:hover,
.insights-link:focus-visible {
  color: #ffffff;
  background: linear-gradient(180deg, #006d2c 0%, #004d1f 100%);
  filter: brightness(.96);
}

.insights-link:active { transform: translateY(1px); }

/* On touch screens, retain the press feedback without leaving a sticky focus colour. */
@media (hover: none) and (pointer: coarse) {
  .insights-link:hover,
  .insights-link:focus-visible {
    color: #006d2c;
    background: #ffffff;
    filter: none;
  }

  .insights-link.is-pressing {
    color: #ffffff;
    background: linear-gradient(180deg, #006d2c 0%, #004d1f 100%);
    filter: brightness(.96);
    transform: translateY(1px);
  }
}

.experience-strip {
  width: min(100%, var(--page-width));
  height: 76.5px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  overflow: hidden;
  clip-path: inset(0 calc(6% + 21px));
}

.experience-track {
  display: flex;
  gap: 0;
  width: max-content;
  white-space: nowrap;
  animation: experience-scroll 64.8615s linear infinite forwards;
}

.experience-track:hover {
  animation-play-state: paused;
}

.experience-track p {
  margin: 0;
  padding-right: 56px;
  color: #000000;
  font: 400 22px/27.5px "Quicksand", sans-serif;
  font-style: normal;
  font-synthesis: none;
  text-align: center;
}

@keyframes experience-scroll {
  to { transform: translateX(-50%); }
}

/* Keep duplicated marquee items flowing across the viewport in Arabic too.
   The page direction is RTL, but the track itself must remain LTR so each
   copy follows the previous one without leaving an empty side. */
html[lang="ar"] .experience-track {
  direction: ltr;
  animation-direction: reverse;
}

html[lang="ar"] .experience-strip {
  direction: ltr;
}

html[lang="ar"] .experience-track p {
  direction: rtl;
  padding-right: 0;
  padding-left: 56px;
  text-align: right;
}

@media (min-width: 1024px) {
  .service-card:hover,
  .service-card:focus-visible {
    box-shadow: 0 16px 30px rgba(24, 81, 39, 0.28);
    filter: brightness(1.06);
    transform: none;
    outline: none;
  }

  .service-card:hover::after,
  .service-card:focus-visible::after {
    transform: translateX(620%) skewX(-18deg);
  }

  .service-card:hover .service-card-content,
  .service-card:focus-visible .service-card-content {
    background: rgba(0, 0, 0, 0);
    transform: scale(1);
    text-shadow: 2px 4px 2px rgba(0, 0, 0, 0.2);
  }

  .service-card:hover::before,
  .service-card:focus-visible::before {
    transform: scale(1.05);
  }
}

.site-footer {
  min-height: 164.8px;
  padding: 56px 24px;
  background: #ffffff;
}

.footer-container {
  width: min(100%, 1112px);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
}

.copyright {
  margin: 0;
  color: var(--muted-text);
  font-size: 16px;
  line-height: 1.8;
}

.powered-by {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: flex-end;
  gap: 4px;
  color: var(--muted-text);
}

.powered-by span {
  line-height: 1.8;
}

.powered-by img {
  width: 131px;
  height: 20px;
  object-fit: contain;
}

@media (max-width: 767px) {
  .experience-strip {
    width: min(100%, var(--page-width));
    clip-path: inset(0 calc(5% + 22px));
  }

  .services-section {
    height: 524px;
    padding: 32px 24px;
  }

  .services-grid {
    width: 100%;
    height: 468px;
    grid-template-columns: 1fr;
    grid-template-rows: repeat(3, 140px);
    gap: 24px;
  }

  .service-card {
    font-size: clamp(22px, 6vw, 28px);
    line-height: 1.2;
  }

  .mission-statement {
    min-height: 192px;
    padding: 38px 24px;
  }

  .mission-statement p {
    font-size: clamp(16px, calc(2.5vw + 8px), 18px);
    direction: ltr;
    text-align: left;
    overflow-wrap: break-word;
  }

  .experience-track p {
    font-size: clamp(16px, 4.5vw, 18px);
    line-height: 1.4;
  }

  .insights-section {
    min-height: 136px;
    padding: 40px 24px;
  }

  .site-footer {
    min-height: 214.4px;
    padding: 48px 24px;
  }

  .footer-container {
    grid-template-columns: 1fr;
    gap: 8px;
    text-align: center;
  }

  .powered-by {
    justify-content: center;
    align-items: center;
  }
}

@media (min-width: 768px) and (max-width: 820px) {
  .services-grid {
    width: 100%;
    gap: 24px;
  }

  .service-card {
    padding-right: 16px;
    padding-left: 16px;
    font-size: 28px;
    line-height: 1.2;
  }

  .service-card-content {
    padding-right: 16px;
    padding-left: 16px;
  }

  .mission-statement {
    margin-top: 32px;
  }
}

@media (max-width: 767px) {
  html[lang="ar"] .mission-statement p {
    width: 100%;
    direction: rtl;
    text-align: right;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
