/* ==========================================================================
   Pary — RTL (Right-to-Left) Overrides for Arabic Language
   ========================================================================== */

[dir="rtl"] {
  text-align: right;
}

/* Base Font Override */
[dir="rtl"] body,
[dir="rtl"] h1, [dir="rtl"] h2, [dir="rtl"] h3,
[dir="rtl"] h4, [dir="rtl"] h5, [dir="rtl"] h6,
[dir="rtl"] .logo-text,
[dir="rtl"] .logo-text span,
[dir="rtl"] .btn,
[dir="rtl"] .section-label,
[dir="rtl"] .filter-tab,
[dir="rtl"] .product-name,
[dir="rtl"] .product-price,
[dir="rtl"] .testimonial-text,
[dir="rtl"] .author-name,
[dir="rtl"] .journal-card-title,
[dir="rtl"] .newsletter-title,
[dir="rtl"] .newsletter-btn,
[dir="rtl"] .footer-col-title {
  font-family: var(--arabic) !important;
}

/* Logo spacing adjustment */
[dir="rtl"] .logo-text span {
  margin-left: 0;
  margin-right: 4px;
}

/* Navigation Link Animation Direction */
[dir="rtl"] .nav-link::after {
  left: auto;
  right: 0;
  transform-origin: right;
}

/* Stats counter display numbers */
[dir="rtl"] .stat-item {
  direction: ltr; /* Keeps numbers like "15 000+" readable */
}

/* Brand Philosophy badge flip */
[dir="rtl"] .philosophy-badge {
  right: auto;
  left: 32px;
}

/* Product card badge alignment swap */
[dir="rtl"] .product-badge {
  left: auto;
  right: 12px;
}

/* Testimonials quote icon flip */
[dir="rtl"] .testimonial-quote-icon {
  right: auto;
  left: 24px;
}

[dir="rtl"] .author-meta {
  text-align: right;
}

/* Blog/Journal badge alignment swap */
[dir="rtl"] .journal-card-badge {
  left: auto;
  right: 14px;
}

/* Footer layout and alignment */
[dir="rtl"] .main-footer {
  text-align: right;
}

[dir="rtl"] .footer-brand-col {
  text-align: right;
}

[dir="rtl"] .footer-logo {
  justify-content: flex-start;
}

[dir="rtl"] .footer-link {
  transition: var(--t);
}

[dir="rtl"] .footer-link:hover {
  padding-left: 0;
  padding-right: 6px;
}

@media (min-width: 768px) {
  [dir="rtl"] .footer-bottom {
    flex-direction: row-reverse;
  }
}

/* Scroll reveal translations swap for RTL (Only applied before element is revealed) */
[dir="rtl"] [data-reveal="fade-left"]:not(.revealed) {
  transform: translateX(24px);
}

[dir="rtl"] [data-reveal="fade-right"]:not(.revealed) {
  transform: translateX(-24px);
}

[dir="rtl"] [data-reveal].revealed {
  opacity: 1 !important;
  transform: translate(0, 0) scale(1) rotate(0deg) !important;
}

/* ==========================================================================
   Hero Section RTL Layout Overrides
   ========================================================================== */
@media (min-width: 1024px) {
  [dir="rtl"] .hero-section {
    background: linear-gradient(75deg, var(--off-white) 46%, var(--green-900) 46%);
  }

  [dir="rtl"] .hero-section::after {
    left: auto;
    right: 54%;
    transform: skewX(8deg);
    transform-origin: top;
  }

  [dir="rtl"] .hero-content {
    padding: 130px 0 80px 64px;
  }
  
  [dir="rtl"] .hero-visual {
    padding: 0 56px 0 0;
  }

  /* Fix card overlap in RTL */
  [dir="rtl"] .philosophy-content-half {
    margin-left: 0 !important;
    margin-right: -80px !important;
  }
}

@media (max-width: 1023px) {
  [dir="rtl"] .hero-section {
    background: var(--green-900) !important;
  }
  [dir="rtl"] .hero-section::after {
    display: none !important;
  }
  [dir="rtl"] .hero-img-backdrop {
    width: 280px !important;
    height: 280px !important;
  }
}

[dir="rtl"] .hero-img-backdrop {
  left: auto;
  right: 50%;
  transform: translateX(50%);
}

[dir="rtl"] .hero-skincare-img {
  box-shadow:
    24px 0 80px rgba(21,40,23,0.25),
    0 -16px 60px rgba(21,40,23,0.08);
}

[dir="rtl"] .hero-float-card--1 {
  left: auto;
  right: 0px;
}

[dir="rtl"] .hero-float-card--2 {
  right: auto;
  left: -24px;
}
