/* ==========================================================================
   Homepage — "علاقات واعية" (front-page.php)
   Loaded on the front page and single posts (fonts and color tokens).
   The site header and footer come from the theme, unchanged.
   ========================================================================== */

@font-face {
  font-family: 'Co Headline';
  src: url('../fonts/co-headline-light.woff2') format('woff2'), url('../fonts/co-headline-light.woff') format('woff');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Co Headline';
  src: url('../fonts/co-headline-regular.woff2') format('woff2'), url('../fonts/co-headline-regular.woff') format('woff');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Co Headline';
  src: url('../fonts/co-headline-bold.woff2') format('woff2'), url('../fonts/co-headline-bold.woff') format('woff');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --rbe-bg: #FEFCFA;
  --rbe-hero-bg: #FAF8F8;
  --rbe-ink: #324158;
  --rbe-orange: #EA7658;
  --rbe-pink: #F5D9E5;
  --rbe-pink-soft: rgba(245, 217, 229, 0.4);
  --rbe-green: #1E9E71;
  --rbe-purple: #B898EF;
  --rbe-blue: #5190DE;
  --rbe-link: #3D9BE9;
  --rbe-link-hover: #305CA4;
  --rbe-blog-card: #D5E0F2;
  --rbe-font: 'Co Headline', 'Cairo', 'IBM Plex Sans Arabic', sans-serif;
}

body.home { background: var(--rbe-bg); }

.rbe-home {
  font-family: var(--rbe-font);
  color: var(--rbe-ink);
}
.rbe-home { overflow: hidden; }
:where(.rbe-home) :where(h1, h2, h3, p, figure, blockquote) { margin: 0; }
.rbe-home svg { display: block; }

.rbe-container { max-width: 980px; margin: 0 auto; padding: 0 20px; }
@media (min-width: 1020px) { .rbe-container { padding: 0; } }

.rbe-sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* ===== Buttons ===== */
.rbe-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 228px;
  height: 50px;
  padding: 0 28px;
  border: 2px solid var(--rbe-ink);
  border-radius: 100px;
  box-shadow: 0 2px 0 1px #1C1B1B;
  font-family: var(--rbe-font);
  font-size: 16px;
  font-weight: 700;
  line-height: 1.5;
  transition: border-color 0.4s ease, background-color 0.4s ease, color 0.4s ease;
}
.rbe-btn--light { background: var(--rbe-bg); color: var(--rbe-ink); }
.rbe-btn--orange { min-width: 201px; background: var(--rbe-orange); color: var(--rbe-bg); }
.rbe-btn:hover { background: #323232; border-color: transparent; color: #fff; }

.rbe-link-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 95px;
  height: 34px;
  padding: 0 10px;
  background: #fff;
  box-shadow: 0 2px 0 0 var(--rbe-link);
  color: var(--rbe-link);
  font-size: 14px;
  font-weight: 700;
  transition: color 0.4s ease;
}
.rbe-link-btn:hover { color: var(--rbe-link-hover); }

/* ===== Hero ===== */
.rbe-hero { background: var(--rbe-hero-bg); }
.rbe-hero__inner {
  display: grid;
  grid-template-columns: 539fr 441fr;
  align-items: center;
  min-height: 636px;
  padding-block: 60px;
}
.rbe-hero__content { padding-inline-start: 12px; }
.rbe-hero__title {
  max-width: 520px;
  margin-bottom: 26px;
  font-size: 45px;
  font-weight: 700;
  line-height: 1.22;
  color: var(--rbe-orange);
}
.rbe-hero__text { max-width: 380px; font-size: 17px; line-height: 1.5; }
.rbe-hero__actions { margin-top: 36px; }
.rbe-hero__media { display: flex; justify-content: flex-end; }
.rbe-hero__image {
  width: 440px;
  max-width: 100%;
  height: auto;
  aspect-ratio: 440 / 398;
  object-fit: cover;
  object-position: 59% 50%;
  -webkit-mask: url('../images/home/hero-mask.svg') center / 100% 100% no-repeat;
  mask: url('../images/home/hero-mask.svg') center / 100% 100% no-repeat;
}

/* ===== Intro ===== */
.rbe-intro { padding-block: 60px 75px; }
.rbe-intro__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}
.rbe-intro__content { max-width: 400px; margin-inline-start: 52px; }
.rbe-intro__lead {
  font-size: 18px;
  font-weight: 300;
  line-height: 1.4;
  letter-spacing: 0.02em;
  color: #D0401A;
}
.rbe-intro__lead-bold { margin-bottom: 1.4em !important; font-size: 18px; font-weight: 700; line-height: 1.4; }
.rbe-intro__text { font-size: 17px; line-height: 1.5; }
.rbe-intro__text p + p { margin-top: 1.5em; }
.rbe-intro__text strong { font-weight: 700; }
.rbe-intro__actions { margin-top: 48px; }
.rbe-intro__media { display: flex; justify-content: center; padding-top: 30px; }
.rbe-intro__illustration { width: 384px; max-width: 100%; height: auto; }

/* ===== About ===== */
.rbe-about { padding-block: 30px 90px; }
.rbe-about__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
}
.rbe-about__media { position: relative; justify-self: center; width: 329px; max-width: 100%; }
.rbe-about__image { width: 329px; max-width: 100%; height: auto; aspect-ratio: 329 / 435; object-fit: cover; }
.rbe-about__heart {
  position: absolute;
  top: 0;
  left: 11px;
  width: 46px;
  height: 57px;
  color: var(--rbe-green);
  transform: rotate(-9.27deg);
}
.rbe-about__flower {
  position: absolute;
  right: -62px;
  bottom: 12px;
  width: 117px;
  height: 151px;
  color: var(--rbe-green);
}
.rbe-about__content { max-width: 420px; margin-inline-start: 9px; }
.rbe-about__title {
  margin-bottom: 16px !important;
  font-size: 24px;
  font-weight: 700;
  line-height: 1.4;
  letter-spacing: 0.02em;
  color: var(--rbe-green);
}
.rbe-about__text { font-size: 17px; line-height: 1.6; }
.rbe-about__actions { margin-top: 36px; }

/* ===== Programs ===== */
.rbe-programs {
  position: relative;
  padding-block: 80px 105px;
  background: var(--rbe-pink);
}
.rbe-programs::before,
.rbe-programs::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  height: 20px;
  background-repeat: repeat-x;
  background-size: 25px 20px;
}
.rbe-programs::before {
  top: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 25 20' preserveAspectRatio='none'%3E%3Cpath d='M0 0h25L12.5 20z' fill='%23FEFCFA'/%3E%3C/svg%3E");
}
.rbe-programs::after {
  bottom: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 25 20' preserveAspectRatio='none'%3E%3Cpath d='M0 20h25L12.5 0z' fill='%23FEFCFA'/%3E%3C/svg%3E");
}
.rbe-programs__title {
  margin-bottom: 56px !important;
  font-size: 45px;
  font-weight: 700;
  line-height: 1.22;
  letter-spacing: 0.03em;
  text-align: center;
}
.rbe-programs__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 474px));
  justify-content: center;
  gap: 16px;
}
.rbe-program {
  position: relative;
  overflow: hidden;
  min-height: 193px;
  padding: 106px 42px 26px 35px;
  border-radius: 16px;
  color: var(--rbe-bg);
}
.rbe-program--orange { --rbe-decor: #FFC48C; background: var(--rbe-orange); }
.rbe-program--purple { --rbe-decor: #5A55B7; background: var(--rbe-purple); }
.rbe-program--blue { --rbe-decor: #2D5AA6; background: var(--rbe-blue); }
.rbe-program--green { --rbe-decor: #2DC38E; background: var(--rbe-green); }
.rbe-program--linked { transition: transform 0.3s ease; }
.rbe-program--linked:hover { transform: translateY(-3px); }
.rbe-program__decor {
  position: absolute;
  top: -28px;
  left: -8px;
  width: 110px;
  height: 136px;
  color: var(--rbe-decor);
  pointer-events: none;
}
.rbe-program__decor svg { width: 100%; height: 100%; }
.rbe-program__decor--square { top: -62px; left: -52px; width: 140px; height: 136px; }
.rbe-program__decor--broken-heart { top: -8px; left: -34px; width: 115px; height: 100px; }
.rbe-program__decor--hearts { top: -34px; left: -48px; width: 140px; height: 120px; }
.rbe-program__badge {
  position: absolute;
  top: 22px;
  right: 39px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 26px;
  padding: 0 14px;
  border: 1px solid var(--rbe-bg);
  border-radius: 100px;
  font-size: 12px;
  line-height: 1;
}
.rbe-program__badge::before {
  content: '';
  flex: 0 0 8px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #F2F2F2;
}
.rbe-program__badge--open::before { background: #BADA55; }
.rbe-program__badge--soon::before { background: #FFB66D; }
.rbe-program__body {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 220px;
  align-items: start;
  gap: 24px;
}
.rbe-program__type { font-size: 16px; line-height: 1.4; }
.rbe-program__title { font-size: 25px; font-weight: 700; line-height: 1.4; color: inherit; }
.rbe-program__desc { font-size: 12px; line-height: 1.6; }
.rbe-program__link { position: absolute; inset: 0; z-index: 2; }

/* ===== Testimonials ===== */
.rbe-testimonials { padding-block: 85px 90px; }
.rbe-testimonials__head { position: relative; margin-bottom: 36px; padding-top: 120px; text-align: center; }
.rbe-testimonials__cloud {
  position: absolute;
  top: 0;
  left: calc(50% - 232px);
  width: 185px;
  height: 127px;
  color: #FFB6C1;
  transform: rotate(-9.27deg);
}
.rbe-testimonials__title { position: relative; font-size: 24px; font-weight: 700; line-height: 1.4; }
.rbe-slider { position: relative; max-width: 934px; margin: 0 auto; }
.rbe-slider__card {
  padding: 38px 100px 40px;
  border-radius: 16px;
  background: var(--rbe-pink-soft);
  text-align: center;
}
.rbe-testimonial:not(.is-active) { display: none; }
.rbe-testimonial__name { margin-bottom: 10px; font-size: 14px; font-weight: 300; line-height: 1.5; }
.rbe-testimonial__quote { max-width: 500px; margin: 0 auto !important; font-size: 20px; line-height: 1.5; }
.rbe-testimonial__quote p + p { margin-top: 1.5em; }
.rbe-testimonial__more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 45px;
  font-size: 12px;
  color: var(--rbe-orange);
}
.rbe-testimonial__more::after { content: '›'; font-size: 16px; line-height: 1; }
.rbe-testimonial__more:hover { text-decoration: underline; }
.rbe-slider__arrow {
  position: absolute;
  top: 105px;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--rbe-orange);
  cursor: pointer;
  transition: opacity 0.3s ease;
}
.rbe-slider__arrow:hover { opacity: 0.7; }
.rbe-slider__arrow svg { width: 100%; height: 100%; }
.rbe-slider__prev { right: 63px; }
.rbe-slider__prev svg { transform: scaleX(-1); }
.rbe-slider__next { left: 49px; }

/* ===== Newsletter ===== */
.rbe-newsletter { padding-block: 0 115px; }
.rbe-newsletter__card {
  display: grid;
  grid-template-columns: 400px minmax(0, 1fr);
  align-items: end;
  gap: 40px;
  max-width: 934px;
  margin: 0 auto;
  padding: 45px 59px 32px 60px;
  border-radius: 30px;
  background: var(--rbe-pink);
}
.rbe-newsletter__title { font-size: 18px; font-weight: 700; line-height: 1.4; }
.rbe-newsletter__subtitle { margin-bottom: 36px !important; font-size: 17px; line-height: 1.5; }
.rbe-newsletter__points { display: grid; gap: 14px; margin: 0 0 44px; padding: 0; list-style: none; }
.rbe-newsletter__points li { display: flex; align-items: flex-start; gap: 16px; font-size: 13px; line-height: 1.4; }
.rbe-newsletter__star { flex: 0 0 19px; width: 19px; height: 18px; margin-top: 1px; color: var(--rbe-orange); }
.rbe-form__row { display: flex; align-items: center; gap: 12px; }
.rbe-form__input {
  flex: 1;
  min-width: 0;
  height: 34px;
  padding: 0 16px;
  border: 0;
  border-radius: 100px;
  background: #fff;
  font-family: var(--rbe-font);
  font-size: 13px;
  color: var(--rbe-ink);
}
.rbe-form__input::placeholder { color: #595959; }
.rbe-form__input:focus { outline: 2px solid var(--rbe-ink); outline-offset: 1px; }
.rbe-form__submit {
  flex: 0 0 91px;
  height: 42px;
  border: 0;
  border-radius: 100px;
  background: var(--rbe-green);
  font-family: var(--rbe-font);
  font-size: 17px;
  font-weight: 700;
  color: #fff;
  cursor: pointer;
  transition: background-color 0.3s ease;
}
.rbe-form__submit:hover { background: #17835D; }
.rbe-form__consent { display: flex; align-items: center; gap: 10px; margin-top: 14px; font-size: 14px; cursor: pointer; }
.rbe-form__consent input {
  -webkit-appearance: none;
  appearance: none;
  flex: 0 0 18px;
  width: 18px;
  height: 18px;
  margin: 0;
  border: 2px solid var(--rbe-ink);
  border-radius: 2px;
  background: transparent center / 12px no-repeat;
  cursor: pointer;
}
.rbe-form__consent input:checked {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M6.2 11.3 2.9 8l-1 1 4.3 4.3 8-8-1-1z' fill='%23324158'/%3E%3C/svg%3E");
}
.rbe-form__message { margin-top: 12px !important; font-size: 14px; }
.rbe-form__message--success { color: var(--rbe-green); }
.rbe-form__message--error { color: #D0401A; }
.rbe-form { position: relative; }
.rbe-honeypot {
  position: absolute;
  top: 0;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
.rbe-newsletter__media { position: relative; justify-self: center; width: 356px; max-width: 100%; }
.rbe-newsletter__scribble { position: absolute; top: 0; left: 0; width: 100%; height: auto; color: var(--rbe-bg); }
.rbe-newsletter__image { position: relative; width: 343px; max-width: 100%; height: auto; margin: 0 auto; }

/* ===== Blog ===== */
.rbe-blog { padding-block: 0 60px; }
.rbe-blog__head,
.rbe-blog__grid { max-width: 934px; margin-inline: auto; }
.rbe-blog__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; }
.rbe-blog__title { font-size: 26px; font-weight: 700; line-height: 1.4; }
.rbe-blog__all { font-size: 12px; color: var(--rbe-blue); text-decoration: underline; }
.rbe-blog__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 21px; }
.rbe-post {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding-bottom: 40px;
  border-radius: 16px;
  background: var(--rbe-blog-card);
  transition: transform 0.3s ease;
}
.rbe-post:hover { transform: translateY(-3px); }
.rbe-post__media { position: relative; height: 209px; }
.rbe-post__media img { width: 100%; height: 100%; object-fit: cover; }
.rbe-post__time {
  position: absolute;
  top: 18px;
  right: 27px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: #fff;
  text-shadow: 0 4px 5px rgba(0, 0, 0, 0.4);
}
.rbe-post__time-label { font-size: 12px; font-weight: 300; }
.rbe-post__time-num { font-size: 14px; }
.rbe-post__title { margin: 22px 27px 0 !important; font-size: 18px; font-weight: 700; line-height: 1.4; }
.rbe-post__excerpt { margin: 20px 27px 0 !important; font-size: 12px; font-weight: 300; line-height: 1.4; }

/* ===== Mobile ===== */
@media (max-width: 767px) {
  .rbe-hero__inner { grid-template-columns: 1fr; gap: 40px; min-height: 0; padding-block: 40px; }
  .rbe-hero__content { padding: 0; }
  .rbe-hero__title { margin-bottom: 8px; font-size: 32px; }
  .rbe-hero__actions { text-align: center; }
  .rbe-hero__media { justify-content: center; }
  .rbe-hero__image { width: 290px; }

  .rbe-intro { padding-block: 40px 30px; }
  .rbe-intro__inner { grid-template-columns: 1fr; }
  .rbe-intro__content { max-width: none; margin: 0; }
  .rbe-intro__actions { text-align: center; }
  .rbe-intro__media { padding-top: 0; }
  .rbe-intro__illustration { width: 290px; }

  .rbe-about { padding-block: 20px 60px; }
  .rbe-about__inner { grid-template-columns: 1fr; gap: 40px; }
  .rbe-about__content { order: -1; max-width: none; margin: 0; }
  .rbe-about__actions { text-align: center; }
  .rbe-about__media { width: 240px; }
  .rbe-about__heart { top: -10px; left: 0; width: 38px; height: 46px; }
  .rbe-about__flower { right: -30px; width: 80px; height: 104px; }

  .rbe-programs { padding-block: 60px 70px; }
  .rbe-programs__title { margin-bottom: 24px !important; font-size: 30px; }
  .rbe-programs__grid { grid-template-columns: 1fr; }
  .rbe-program { min-height: 305px; padding: 130px 20px 26px; }
  .rbe-program__badge { right: 20px; }
  .rbe-program__body { grid-template-columns: 1fr; gap: 12px; }
  .rbe-program__title { font-size: 30px; }
  .rbe-program__decor { top: -10px; left: -20px; width: 130px; height: 160px; }
  .rbe-program__decor--square { top: -40px; left: -60px; width: 170px; height: 170px; }
  .rbe-program__decor--broken-heart { top: 20px; left: -40px; width: 140px; height: 130px; }
  .rbe-program__decor--hearts { top: 10px; left: -50px; width: 160px; height: 150px; }

  .rbe-testimonials { padding-block: 40px 40px; }
  .rbe-testimonials__head { padding-top: 110px; }
  .rbe-testimonials__cloud { left: calc(50% - 130px); width: 150px; height: 103px; }
  .rbe-slider__card { padding: 24px 20px 30px; }
  .rbe-testimonial__quote { font-size: 17px; }
  .rbe-slider__nav { display: flex; justify-content: center; gap: 12px; margin-top: 16px; }
  .rbe-slider__arrow { position: static; width: 28px; height: 28px; }

  .rbe-newsletter { padding-block: 20px 60px; }
  .rbe-newsletter__card { grid-template-columns: 1fr; gap: 24px; padding: 30px 14px 36px; }
  .rbe-newsletter__media { order: -1; width: 240px; }
  .rbe-newsletter__subtitle { margin-bottom: 24px !important; }
  .rbe-newsletter__points { margin-bottom: 30px; }
  .rbe-form__row { flex-direction: column; align-items: stretch; }
  .rbe-form__submit { flex: 0 0 auto; }

  .rbe-blog__grid { grid-template-columns: 1fr; gap: 24px; }
  .rbe-post { padding: 14px 0 40px; }
  .rbe-post__media { height: 148px; margin: 0 14px; }
  .rbe-post__time { right: 14px; }
  .rbe-post__title { margin: 18px 14px 0 !important; }
  .rbe-post__excerpt { margin: 10px 14px 0 !important; }
}
