.fy-footer {
  position: relative;
  margin-top: 142px;
  padding-block: 6px 12px;
  background: var(--fy-primary);
  color: #ffffff;
  overflow-x: clip;
  overflow-y: visible;
  isolation: isolate;
}

/* نفس قياس دائرة الهيرو، لكن طالعة لفوق */
.fy-footer__curve {
  position: absolute;
  left: 50%;
  top: -142px;
  width: 138%;
  height: 250px;
  transform: translateX(-50%);
  background: var(--fy-primary);
  border-radius: 50% 50% 0 0 / 75% 75% 0 0;
  z-index: 0;
  pointer-events: none;
}

.fy-footer__pattern {
  position: absolute;
  top: -142px;
  bottom: 0;
  right: 0;
  left: auto;
  width: min(24vw, 240px);
  opacity: 1;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
  background-image: url("../images/main/main.svg");
  background-repeat: no-repeat;
  background-position: right top;
  background-size: 100% auto;
  clip-path: polygon(0 22px, 100% 58px, 100% 100%, 0 100%);
}

.fy-footer__pattern.is-inline-svg {
  background-image: none;
}

.fy-footer__pattern svg,
.fy-footer .fy-pattern-svg {
  position: absolute;
  top: 0;
  right: 0;
  left: auto;
  width: 100%;
  height: auto;
  max-width: none;
  display: block;
  transform: scaleX(-1);
  transform-origin: center;
}

.fy-footer .fy-pattern-shape {
  transform-box: fill-box;
  transform-origin: center;
  animation: fyPatternShapeBlink 4.8s ease-in-out infinite;
  animation-delay: var(--fy-shape-delay, 0s);
  will-change: opacity, transform;
}

.fy-footer__container {
  position: relative;
  z-index: 6;
  width: 100%;
  max-width: none;
  padding-inline: clamp(80px, 6.5vw, 124px);
  margin-top: -78px;
}

.fy-footer__inner {
  display: grid;
  grid-template-columns: 240px minmax(360px, 1fr) minmax(320px, 390px);
  grid-template-areas: "social contact intro";
  gap: 46px;
  align-items: start;
  direction: ltr;
}

.fy-footer__col {
  min-width: 0;
  direction: rtl;
}

/* العمود اليسار */
.fy-footer__col--social {
  grid-area: social;
  width: 240px;
  justify-self: start;
  text-align: right;
  padding-top: 4px;
}

.fy-footer__social-title {
  margin: 0 0 12px;
  color: #ffffff;
  font-size: 15px;
  line-height: 1.4;
  font-weight: var(--fy-hero-title-weight);
}

.fy-footer__social-links {
  width: 150px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0;
  margin-bottom: 16px;
}

.fy-footer__social-link {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.16);
  transition:
    background var(--fy-transition),
    color var(--fy-transition);
}

.fy-footer__social-link:hover {
  transform: none;
  background: #ffffff;
}

.fy-footer__social-link img {
  width: 18px;
  height: 18px;
  display: block;
  object-fit: contain;
  filter: brightness(0) saturate(100%) invert(100%);
  transition: filter var(--fy-transition);
}

.fy-footer__social-link:hover img {
  filter: brightness(0) saturate(100%) invert(22%) sepia(22%) saturate(1436%) hue-rotate(180deg) brightness(95%) contrast(90%);
}

.fy-footer__map {
  width: 150px;
  height: 148px;
  border-radius: 16px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 14px 28px rgba(0, 0, 0, 0.14);
}

.fy-footer__map iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* العمود الوسط */
.fy-footer__col--contact {
  grid-area: contact;
  width: min(100%, 500px);
  justify-self: center;
  text-align: right;
  padding-top: 18px;
}

.fy-footer__info-list {
  display: flex;
  flex-direction: column;
  gap: 22px;
}

/* الأيقونة أمام النص مباشرة */
.fy-footer__info-item {
  display: flex;
  flex-direction: row;
  align-items: flex-start;
  justify-content: flex-start;
  gap: 10px;
  direction: rtl;
  text-align: right;
  width: 100%;
}

.fy-footer__info-icon {
  flex: 0 0 26px;
  width: 26px;
  height: 26px;
  display: block;
  object-fit: contain;
  margin-top: 2px;
  filter: brightness(0) saturate(100%) invert(28%) sepia(95%) saturate(2713%) hue-rotate(337deg) brightness(97%) contrast(96%);
}

.fy-footer__info-text {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  color: #ffffff;
  font-size: 14px;
  line-height: 1.65;
  font-weight: 400;
  text-align: right;
}

.fy-footer__info-text strong {
  color: #ffffff;
  font-size: 15px;
  font-weight: 400;
}

.fy-footer__info-text [dir="ltr"] {
  text-align: right;
  unicode-bidi: isolate;
  white-space: nowrap;
  font-weight: 400;
}

/* العمود اليمين */
.fy-footer__col--intro {
  grid-area: intro;
  justify-self: end;
  text-align: right;
}

.fy-footer__brand {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  margin-bottom: 30px;
}

.fy-footer__brand img {
  width: min(100%, 215px);
  height: auto;
  display: block;
}

/* نفس حجم وسمك النص الرئيسي في الهيرو */
.fy-footer__title {
  margin: 0;
  color: #ffffff;
  font-size: var(--fy-hero-title-size);
  font-weight: var(--fy-hero-title-weight);
  line-height: var(--fy-hero-title-line);
  letter-spacing: -0.4px;
}

.fy-footer__title-underline {
  display: block;
  width: 116px;
  height: 13px;
  margin-top: 6px;
}

.fy-footer__title-underline img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: fill;
}

.fy-footer__desc {
  margin: 8px 0 0;
  max-width: 365px;
  color: rgba(255, 255, 255, 0.97);
  font-size: 15px;
  line-height: 1.9;
  font-weight: 400;
  letter-spacing: 0;
}

/* أسفل الفوتر */
.fy-footer__bottom {
  position: relative;
  z-index: 7;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  margin-top: 16px;
  padding-top: 16px;
  clear: both;
  direction: ltr;
}

.fy-footer__bottom::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 1px;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.78) 16%,
    rgba(255, 255, 255, 0.78) 84%,
    rgba(255, 255, 255, 0) 100%
  );
}

.fy-footer__bottom p {
  display: block;
  margin: 0;
  color: rgba(255, 255, 255, 0.94);
  font-size: 15px;
  line-height: 1.5;
  font-weight: 400;
}

.fy-footer__credit {
  direction: rtl;
  text-align: right;
}

.fy-footer__credit-link {
  color: rgba(255, 255, 255, 0.94);
  text-decoration: none;
  transition: opacity var(--fy-transition);
}

.fy-footer__credit-link:hover {
  opacity: 0.8;
}

/* Responsive */
@media (prefers-reduced-motion: reduce) {
  .fy-footer .fy-pattern-shape {
    animation: none;
  }

  .fy-footer__social-link {
    transition: none;
  }

  .fy-footer__credit-link {
    transition: none;
  }
}

@media (max-width: 1200px) {
  .fy-footer__container {
    padding-inline: clamp(44px, 5vw, 76px);
    margin-top: -66px;
  }

  .fy-footer__inner {
    grid-template-columns: 220px minmax(340px, 1fr) minmax(290px, 0.92fr);
    gap: 36px;
  }

  .fy-footer__col--social {
    width: 220px;
  }

  .fy-footer__brand img {
    width: min(100%, 200px);
  }
}

@media (max-width: 992px) {
  .fy-footer {
    margin-top: 112px;
    padding-block: 8px 16px;
  }

  .fy-footer__curve {
    top: -112px;
    width: 160%;
    height: 200px;
  }

  .fy-footer__pattern {
    top: -112px;
    width: min(40vw, 280px);
    opacity: 0.65;
    clip-path: polygon(0 30px, 100% 72px, 100% 100%, 0 100%);
  }

  .fy-footer__container {
    padding-inline: 24px;
    margin-top: -46px;
  }

  .fy-footer__inner {
    grid-template-columns: minmax(245px, 0.88fr) minmax(320px, 1.12fr);
    grid-template-areas:
      "intro intro"
      "social contact";
    gap: 28px 34px;
    align-items: start;
  }

  .fy-footer__col--intro {
    width: 100%;
    justify-self: center;
    text-align: center;
  }

  .fy-footer__brand {
    justify-content: center;
    margin-bottom: 24px;
  }

  .fy-footer__title-underline {
    margin-inline: auto;
  }

  .fy-footer__desc {
    max-width: 560px;
    margin: 8px auto 0;
    line-height: 1.85;
    text-align: center;
  }

  .fy-footer__col--contact {
    width: 100%;
    max-width: 520px;
    justify-self: end;
    padding-top: 4px;
    text-align: right;
  }

  .fy-footer__info-list {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 18px;
  }

  .fy-footer__info-item {
    width: 100%;
    display: grid;
    grid-template-columns: 26px minmax(0, 1fr);
    align-items: start;
    justify-content: start;
    gap: 10px;
    direction: rtl;
    text-align: right;
  }

  .fy-footer__info-icon {
    grid-column: 1;
    width: 25px;
    height: 25px;
    margin-top: 3px;
  }

  .fy-footer__info-text {
    grid-column: 2;
    text-align: right;
  }

  .fy-footer__info-text [dir="ltr"] {
    text-align: right;
    white-space: nowrap;
  }

  .fy-footer__col--social {
    width: 100%;
    max-width: 270px;
    justify-self: start;
    padding-top: 4px;
    text-align: center;
  }

  .fy-footer__social-title {
    text-align: center;
  }

  .fy-footer__social-links {
    width: auto;
    display: inline-flex;
    justify-content: center;
    gap: 10px;
    margin-inline: auto;
    margin-bottom: 16px;
  }

  .fy-footer__map {
    width: min(100%, 260px);
    height: 168px;
    margin-inline: auto;
  }

  .fy-footer__bottom {
    margin-top: 18px;
    padding-top: 16px;
  }
}

@media (max-width: 760px) {
  .fy-footer__inner {
    grid-template-columns: 1fr;
    grid-template-areas:
      "intro"
      "contact"
      "social";
    gap: 26px;
  }

  .fy-footer__col--contact,
  .fy-footer__col--social {
    justify-self: center;
  }

  .fy-footer__col--contact {
    width: 100%;
    max-width: 500px;
    text-align: center;
  }

  .fy-footer__info-list {
    width: min(100%, 430px);
    max-width: 430px;
    margin-inline: auto;
    align-items: stretch;
    gap: 17px;
  }

  .fy-footer__info-item {
    width: 100%;
    margin-inline: auto;
    display: grid;
    grid-template-columns: 26px minmax(0, 1fr);
    align-items: start;
    justify-content: start;
    gap: 10px;
    direction: rtl;
    text-align: right;
  }

  .fy-footer__info-icon {
    grid-column: 1;
    justify-self: start;
    width: 25px;
    height: 25px;
    margin-top: 3px;
  }

  .fy-footer__info-text {
    grid-column: 2;
    width: 100%;
    text-align: right;
  }

  .fy-footer__info-text strong {
    display: block;
    text-align: right;
  }

  .fy-footer__info-text span {
    display: block;
    text-align: right;
  }

  .fy-footer__info-text [dir="ltr"] {
    text-align: right;
    white-space: nowrap;
  }

  .fy-footer__col--social {
    --fy-footer-social-block-width: 158px;

    width: min(100%, 480px);
    max-width: 480px;
    display: grid;
    grid-template-columns: minmax(108px, 0.78fr) minmax(var(--fy-footer-social-block-width), auto);
    grid-template-areas:
      "map title"
      "map links";
    align-items: start;
    justify-content: center;
    gap: 0 16px;
    direction: ltr;
    padding-top: 0;
    text-align: right;
  }

  .fy-footer__social-title {
    grid-area: title;
    width: var(--fy-footer-social-block-width);
    margin: 0 0 10px;
    text-align: right;
    direction: rtl;
    white-space: nowrap;
    justify-self: end;
    align-self: end;
  }

  .fy-footer__social-links {
    grid-area: links;
    width: var(--fy-footer-social-block-width);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0;
    margin: 0;
    direction: rtl;
    justify-self: end;
  }

  .fy-footer__map {
    grid-area: map;
    width: 100%;
    height: 176px;
    margin: 0;
    justify-self: stretch;
  }
}

@media (max-width: 680px) {
  .fy-footer {
    margin-top: 112px;
    padding-block: 6px 14px;
  }

  .fy-footer__curve {
    top: -112px;
    width: 160%;
    height: 200px;
  }

  .fy-footer__container {
    padding-inline: 20px;
    margin-top: -38px;
  }

  .fy-footer__pattern {
    top: -112px;
    width: 52vw;
    opacity: 0.46;
    clip-path: polygon(0 4px, 100% 24px, 100% 100%, 0 100%);
  }

  .fy-footer__inner {
    gap: 24px;
  }

  .fy-footer__brand {
    margin-bottom: 22px;
  }

  .fy-footer__desc {
    max-width: 440px;
    font-size: 14px;
    line-height: 1.8;
  }

  .fy-footer__info-text {
    font-size: 13.5px;
  }

  .fy-footer__info-text strong,
  .fy-footer__social-title,
  .fy-footer__bottom p {
    font-size: 14px;
  }

  .fy-footer__bottom {
    flex-wrap: wrap;
    justify-content: center;
    text-align: center;
    row-gap: 6px;
  }

  .fy-footer__credit {
    text-align: center;
  }
}

@media (max-width: 480px) {
  .fy-footer {
    margin-top: 100px;
    padding-block: 6px 12px;
  }

  .fy-footer__curve {
    top: -100px;
    width: 190%;
    height: 178px;
  }

  .fy-footer__container {
    padding-inline: 18px;
    margin-top: -30px;
  }

  .fy-footer__pattern {
    top: -100px;
    width: 58vw;
    opacity: 0.34;
    clip-path: polygon(0 0, 100% 22px, 100% 100%, 0 100%);
  }

  .fy-footer__brand {
    margin-bottom: 22px;
  }

  .fy-footer__brand img {
    width: min(100%, 182px);
  }

  .fy-footer__title-underline {
    width: 104px;
  }

  .fy-footer__desc {
    font-size: 13.5px;
  }

  .fy-footer__info-list {
    width: min(100%, 360px);
    gap: 16px;
  }

  .fy-footer__info-item {
    grid-template-columns: 24px minmax(0, 1fr);
    gap: 9px;
  }

  .fy-footer__info-icon {
    width: 23px;
    height: 23px;
  }

  .fy-footer__info-text [dir="ltr"] {
    white-space: normal;
  }

  .fy-footer__col--social {
    --fy-footer-social-block-width: 150px;

    grid-template-columns: minmax(106px, 0.78fr) minmax(var(--fy-footer-social-block-width), auto);
    gap: 0 12px;
  }

  .fy-footer__social-link {
    width: 30px;
    height: 30px;
  }

  .fy-footer__map {
    height: 150px;
  }

  .fy-footer__bottom {
    margin-top: 14px;
  }

  .fy-footer__bottom p {
    font-size: 13px;
  }
}