@charset "UTF-8";
/* ==========================================================================
   About (من نحن)
   ========================================================================== */

.about {
  position: relative;
  min-height: 567px;
  padding-top: 32px;
  padding-bottom: 106px;
  overflow: hidden;
}

/* Decorative stairs (Group 1 / mirrored copy), top corners */
.about__stairs {
  position: absolute;
  top: 0;
  width: 228px;
  height: 240px;
  max-width: none;
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
}
.about__stairs--left {
  left: 0;
}
.about__stairs--right {
  right: 0;
  transform: scaleX(-1);
}

/*
 * Entrance (Figma "سكشن من نحن": Default -> Variant4, smart animate, ease-in-out 0.8s):
 * the title rises 32px, the subtitle and stairs fade in, and the three cards
 * slide up from below the section while fading in, all at the same time.
 */
.about.is-visible .about__stairs {
  opacity: 1;
}
.about__head {
  transform: translateY(32px);
  transition: transform 0.8s ease-in-out;
}
.about__subtitle {
  opacity: 0;
  transition: opacity 0.8s ease-in-out;
}
.about.is-visible .about__head {
  transform: none;
}
.about.is-visible .about__subtitle {
  opacity: 1;
}

.about__head {
  width: 426px;
  max-width: 100%;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 32px;
}

.about__title {
  min-height: 55px;
  display: flex;
  align-items: center;
}

.about__subtitle {
  padding: 10px;
  font-size: var(--fs-sub2);
  line-height: 1.4;
  color: var(--c-gray-dark-active);
  text-align: center;
}

.about__cards {
  margin-top: 81px;
  display: flex;
  justify-content: center;
  gap: 20px;
}

.card {
  position: relative;
  flex: 0 1 400px;
  height: 220px;
  border-top-left-radius: 16px;
  border-bottom-right-radius: 16px;
  background: var(--c-gray-light);
  filter: drop-shadow(0 4px 2px rgba(0, 0, 0, 0.15));
  overflow: hidden;
  outline: none;
  cursor: default;
  opacity: 0;
  transform: translateY(706px);
  transition: opacity 0.8s ease-in-out, transform 0.8s ease-in-out;
}

.about.is-visible .card {
  opacity: 1;
  transform: none;
}

/* Decorative red corner (Figma 869:15255 — box 88 x 74 at the card's top-right) */
.card__corner {
  position: absolute;
  z-index: 2;
  top: -1px;
  right: -1px;
  width: 89px;
  height: 75px;
  max-width: none;
  pointer-events: none;
  transition: opacity 0.5s ease-in-out;
}

.card:hover .card__corner,
.card:focus-visible .card__corner {
  opacity: 0;
}

.card__front,
.card__back {
  position: absolute;
  inset: 0;
  /* Prototype: hover is a dissolve between the two variants (no movement) */
  transition: opacity 0.5s ease-in-out;
}

.card__front {
  display: flex;
  align-items: center;
  justify-content: center;
}

.card__title {
  font-size: var(--fs-h3);
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

.card--vision .card__title {
  width: 297px;
  background-image: linear-gradient(to right, var(--c-secondary) 35.69%, var(--c-primary) 67.34%);
}

.card--mission .card__title {
  width: 266px;
  background-image: linear-gradient(to left, var(--c-primary), var(--c-secondary));
}

.card--values .card__title {
  width: 266px;
  background-image: linear-gradient(to right, var(--c-secondary) 29.887%, var(--c-primary) 69.361%);
}

/* Hover state (Figma Variant2) */
/* Hover gradient, the same on all three cards (Figma Variant2: #ED4E38 -> #003059,
   left to right, with the orange stop just outside the left edge) */
.card__back {
  padding: 40px 39px 20px;
  background-image: linear-gradient(to right, var(--c-secondary) -28%, var(--c-primary) 100%);
  color: var(--c-white);
  opacity: 0;
  text-align: right;
}


.card--mission .card__back {
  padding-inline: 19px 26px;
}


.card__back-title {
  font-size: var(--fs-sub1);
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 16px;
}

.card--mission .card__back-title {
  padding-inline-start: 20px;
  margin-bottom: 8px;
}

.card__back-body {
  font-size: var(--fs-sub2);
  line-height: 1.2;
  /* Justified: every line starts and ends at the same edge (kashida fills the lines,
     js/kashida.js); the last line stays on the right */
  text-align: justify;
  text-align-last: right;
}

.card--mission .card__back-body {
  font-size: 16px;
  line-height: 1.35;
}

.card--values .card__back-body {
  margin-top: 24px;
  font-size: 16px;
  line-height: 1.35;
  text-align: center;
  text-align-last: center; /* two short lines (3 values, then 2), centred in the card */
  white-space: nowrap; /* keep each line whole, so it is always 3 on top and 2 below */
}

.card:hover,
.card:focus-visible {
  filter: drop-shadow(0 4px 2px rgba(0, 0, 0, 0.08));
}
.card:hover .card__front,
.card:focus-visible .card__front {
  opacity: 0;
}
.card:hover .card__back,
.card:focus-visible .card__back {
  opacity: 1;
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .about__stairs {
    width: 150px;
    height: 158px;
  }
  .card--mission .card__back-body {
    font-size: 14px;
  }
}
@media (max-width: 992px) {
  .about {
    padding-bottom: 48px;
  }
  .about__cards {
    flex-direction: column;
    align-items: center;
    margin-top: 48px;
  }
  .card {
    flex: none;
    width: 100%;
    max-width: 400px;
  }
}
@media (max-width: 576px) {
  .about__stairs {
    width: 96px;
    height: 101px;
  }
  .about__head {
    gap: 12px;
  }
  .card__title {
    width: auto !important;
  }
}
